]> git.saurik.com Git - apt.git/blob - test/integration/test-apt-cli-list
only consider versioned kernel packages in autoremove
[apt.git] / test / integration / test-apt-cli-list
1 #!/bin/sh
2 set -e
3
4 TESTDIR=$(readlink -f $(dirname $0))
5 . $TESTDIR/framework
6
7 setupenvironment
8 configarchitecture "i386"
9
10 if [ ! -x ${BUILDDIRECTORY}/apt ]; then
11 msgmsg "No ${BUILDDIRECTORY}/apt"
12 msgskip
13 exit 0
14 fi
15
16 insertpackage 'unstable' 'foo' 'all' '1.0'
17 insertinstalledpackage 'bar' 'i386' '1.0'
18
19 insertinstalledpackage 'foobar' 'i386' '1.0'
20 insertpackage 'unstable' 'foobar' 'i386' '2.0'
21
22 setupaptarchive
23
24 APTARCHIVE=$(readlink -f ./aptarchive)
25
26 testequal "Listing...
27 bar/now 1.0 i386 [installed,local]
28 foo/unstable 1.0 all
29 foobar/unstable 2.0 i386 [upgradable from: 1.0]" apt list
30
31 testequal "Listing...
32 foo/unstable 1.0 all
33 foobar/unstable 2.0 i386 [upgradable from: 1.0]" apt list "foo*"
34
35 testequal "Listing...
36 foobar/unstable 2.0 i386 [upgradable from: 1.0]" apt list --upgradable
37
38 # FIXME: hm, hm - does it make sense to have this different? shouldn't
39 # we use "installed,upgradable" consitently?
40 testequal "Listing...
41 bar/now 1.0 i386 [installed,local]
42 foobar/now 1.0 i386 [installed,upgradable to: 2.0]" apt list --installed
43
44 testequal "Listing...
45 foobar/unstable 2.0 i386 [upgradable from: 1.0]
46 foobar/now 1.0 i386 [installed,upgradable to: 2.0]
47 " apt list foobar --all-versions
48
49 testequal "Listing...
50 bar/now 1.0 i386 [installed,local]
51 an autogenerated dummy bar=1.0/installed
52 " apt list bar --verbose
53