summaryrefslogtreecommitdiff
path: root/test/integration/test-apt-get-autoremove-kernel-module-providers
blob: 76c00305112a787872f37f62c999dcf707142146 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
#!/bin/sh
set -e

TESTDIR="$(readlink -f "$(dirname "$0")")"
. "$TESTDIR/framework"
setupenvironment
configarchitecture 'amd64'

insertinstalledpackage 'old-kernel-modules-0.8' 'all' '1' 'Depends: linux-image-0.8
Provides: old-module
Source: kernel-module'
insertinstalledpackage 'old-kernel-modules-0.9' 'all' '1' 'Depends: linux-image-0.9
Provides: old-module
Source: kernel-module'
insertinstalledpackage 'kernel-modules-1.0' 'all' '1' 'Depends: linux-image-1.0
Provides: module
Source: kernel-module'
insertinstalledpackage 'kernel-modules-1.1' 'all' '2' 'Depends: linux-image-1.1
Provides: module
Source: kernel-module'
insertinstalledpackage 'kernel-modules-1.2' 'all' '2' 'Depends: linux-image-1.2
Provides: module
Source: kernel-module'
insertinstalledpackage 'kernel-modules-2.0' 'all' '2' 'Depends: linux-image-2.0
Provides: module
Source: kernel-module'
insertinstalledpackage 'kernel-modules-2.1' 'all' '2' 'Depends: linux-image-2.1
Provides: module
Source: kernel-module'
insertinstalledpackage 'texteditor-gtk' 'all' '2' 'Provides: editor
Source: texteditor'
insertinstalledpackage 'texteditor-kde' 'all' '2' 'Provides: editor
Source: texteditor'

insertinstalledpackage 'linux-image-0.8' 'all' '0.8' 'Provides: linux-image
Source: linux-image'
insertinstalledpackage 'linux-image-0.9' 'all' '0.9' 'Provides: linux-image
Source: linux-image'
insertinstalledpackage 'linux-image-1.0' 'all' '1.0' 'Provides: linux-image
Source: linux-image'
insertinstalledpackage 'linux-image-1.1' 'all' '1.1' 'Provides: linux-image
Source: linux-image'
insertinstalledpackage 'linux-image-1.2' 'all' '1.2' 'Provides: linux-image
Source: linux-image'
insertinstalledpackage 'linux-image-2.0' 'all' '2.0' 'Provides: linux-image
Source: linux-image'
insertinstalledpackage 'linux-image-2.1' 'all' '2.1' 'Provides: linux-image
Source: linux-image'
insertinstalledpackage 'has-needs' 'all' '1' 'Depends: editor, module, linux-image'
insertinstalledpackage 'old-needs' 'all' '1' 'Depends: old-module'

testsuccess aptmark auto 'linux-image-*' 'old-kernel-modules-*' 'kernel-modules-*' 'texteditor-*'
testsuccessequal 'kernel-modules-1.0
kernel-modules-1.1
kernel-modules-1.2
kernel-modules-2.0
kernel-modules-2.1
linux-image-0.8
linux-image-0.9
linux-image-1.0
linux-image-1.1
linux-image-1.2
linux-image-2.0
linux-image-2.1
old-kernel-modules-0.8
old-kernel-modules-0.9
texteditor-gtk
texteditor-kde' aptmark showauto

testsuccess aptget check -s
testsuccessequal 'Reading package lists...
Building dependency tree...
Reading state information...
The following packages will be REMOVED:
  kernel-modules-1.0 kernel-modules-1.1 kernel-modules-1.2 linux-image-1.0
  linux-image-1.1 linux-image-1.2
0 upgraded, 0 newly installed, 6 to remove and 0 not upgraded.
Remv kernel-modules-1.0 [1]
Remv kernel-modules-1.1 [2]
Remv kernel-modules-1.2 [2]
Remv linux-image-1.0 [1.0]
Remv linux-image-1.1 [1.1]
Remv linux-image-1.2 [1.2]' apt autoremove -s

testsuccessequal 'Reading package lists...
Building dependency tree...
Reading state information...
The following packages will be REMOVED:
  kernel-modules-1.0 kernel-modules-1.1 kernel-modules-1.2 linux-image-0.8
  linux-image-0.9 linux-image-1.0 linux-image-1.1 linux-image-1.2
  old-kernel-modules-0.8 old-kernel-modules-0.9 old-needs
0 upgraded, 0 newly installed, 11 to remove and 0 not upgraded.
Remv kernel-modules-1.0 [1]
Remv kernel-modules-1.1 [2]
Remv kernel-modules-1.2 [2]
Remv old-needs [1]
Remv old-kernel-modules-0.8 [1]
Remv linux-image-0.8 [0.8]
Remv old-kernel-modules-0.9 [1]
Remv linux-image-0.9 [0.9]
Remv linux-image-1.0 [1.0]
Remv linux-image-1.1 [1.1]
Remv linux-image-1.2 [1.2]' apt autoremove -s old-needs-