test-apt-cli-show 875 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. #!/bin/sh
  2. set -e
  3. TESTDIR=$(readlink -f $(dirname $0))
  4. . $TESTDIR/framework
  5. setupenvironment
  6. configarchitecture "i386"
  7. if [ ! -x ${BUILDDIRECTORY}/apt ]; then
  8. msgmsg "No ${BUILDDIRECTORY}/apt"
  9. msgskip
  10. exit 0
  11. fi
  12. DESCR='Some description
  13. That has multiple lines'
  14. insertpackage 'unstable' 'foo' 'all' '1.0' '' '' "$DESCR"
  15. insertinstalledpackage 'foo' 'all' '1.0'
  16. setupaptarchive
  17. APTARCHIVE=$(readlink -f ./aptarchive)
  18. # note that we do not display Description-md5 with the "apt" cmd
  19. # and also show some additional fields that are calculated
  20. testequal "Package: foo
  21. Priority: optional
  22. Section: other
  23. Installed-Size: 43.0 kB
  24. Maintainer: Joe Sixpack <joe@example.org>
  25. Version: 1.0
  26. Download-Size: unknown
  27. APT-Manual-Installed: yes
  28. APT-Sources: file:$APTARCHIVE/ unstable/main i386 Packages
  29. Description: Some description
  30. That has multiple lines
  31. " apt show foo