summaryrefslogtreecommitdiff
path: root/test/integration/test-apt-cli-show
diff options
context:
space:
mode:
Diffstat (limited to 'test/integration/test-apt-cli-show')
-rwxr-xr-xtest/integration/test-apt-cli-show76
1 files changed, 76 insertions, 0 deletions
diff --git a/test/integration/test-apt-cli-show b/test/integration/test-apt-cli-show
index a37dbd8e6..4f9e9a16c 100755
--- a/test/integration/test-apt-cli-show
+++ b/test/integration/test-apt-cli-show
@@ -20,6 +20,8 @@ insertpackage 'unstable' 'bar' 'i386,amd64' '1' '' '' "$DESCR"
insertpackage 'unstable' 'big' 'i386,amd64' '1' 'Installed-Size: 4129421' '' "$DESCR"
insertpackage 'unstable' 'large' 'all' '1' "Provides: pkga$(generatelotsofnames)" '' "$DESCR"
insertpackage 'unstable' 'large2' 'all' '1' "Provides: foobar, pkga$(generatelotsofnames)" '' "$DESCR"
+insertpackage 'unstable' 'multi' 'all' '1.0' '' '' "$DESCR"
+insertpackage 'unstable' 'multi' 'all' '2.0' '' '' "$DESCR"
insertinstalledpackage 'foo' 'all' '1.0'
setupaptarchive
@@ -99,6 +101,80 @@ Description: Some description
That has multiple lines
" apt show large2
+# Test for multiple versions
+testsuccessequal "Package: multi
+Version: 2.0
+Priority: optional
+Section: other
+Maintainer: Joe Sixpack <joe@example.org>
+Installed-Size: 43.0 kB
+Download-Size: unknown
+APT-Sources: file:$APTARCHIVE unstable/main all Packages
+Description: Some description
+ That has multiple lines
+
+N: There is 1 additional record. Please use the '-a' switch to see it" apt show multi
+
+testsuccessequal "Package: multi
+Version: 2.0
+Priority: optional
+Section: other
+Maintainer: Joe Sixpack <joe@example.org>
+Installed-Size: 43.0 kB
+Download-Size: unknown
+APT-Sources: file:$APTARCHIVE unstable/main all Packages
+Description: Some description
+ That has multiple lines
+
+Package: multi
+Version: 1.0
+Priority: optional
+Section: other
+Maintainer: Joe Sixpack <joe@example.org>
+Installed-Size: 43.0 kB
+Download-Size: unknown
+APT-Sources: file:$APTARCHIVE unstable/main all Packages
+Description: Some description
+ That has multiple lines
+" apt show multi -a
+
+# test apt info
+testsuccessequal "Package: multi
+Version: 2.0
+Priority: optional
+Section: other
+Maintainer: Joe Sixpack <joe@example.org>
+Installed-Size: 43.0 kB
+Download-Size: unknown
+APT-Sources: file:$APTARCHIVE unstable/main all Packages
+Description: Some description
+ That has multiple lines
+
+N: There is 1 additional record. Please use the '-a' switch to see it" apt info multi
+
+testsuccessequal "Package: multi
+Version: 2.0
+Priority: optional
+Section: other
+Maintainer: Joe Sixpack <joe@example.org>
+Installed-Size: 43.0 kB
+Download-Size: unknown
+APT-Sources: file:$APTARCHIVE unstable/main all Packages
+Description: Some description
+ That has multiple lines
+
+Package: multi
+Version: 1.0
+Priority: optional
+Section: other
+Maintainer: Joe Sixpack <joe@example.org>
+Installed-Size: 43.0 kB
+Download-Size: unknown
+APT-Sources: file:$APTARCHIVE unstable/main all Packages
+Description: Some description
+ That has multiple lines
+" apt info multi -a
+
# this is the default, but disabled by the testcases
testsuccess apt show foo -o Apt::Cmd::Disable-Script-Warning=0
cp rootdir/tmp/testsuccess.output aptshow.output