]>
Commit | Line | Data |
---|---|---|
6a910c9d DK |
1 | #!/bin/sh |
2 | set -e | |
3 | ||
4 | TESTDIR=$(readlink -f $(dirname $0)) | |
5 | . $TESTDIR/framework | |
6 | setupenvironment | |
ea65d079 | 7 | configarchitecture 'i386' 'amd64' |
6a910c9d DK |
8 | |
9 | buildsimplenativepackage 'libc6' 'i386' '1.0' 'stable' | |
10 | buildsimplenativepackage 'libc6' 'amd64' '1.0' 'stable' | |
11 | buildsimplenativepackage 'libc6' 'all' '2.0' 'testing' | |
12 | ||
13 | buildsimplenativepackage 'foobar' 'i386' '1.0' 'stable' 'Depends: libc6' | |
14 | buildsimplenativepackage 'foobar' 'amd64' '1.0' 'stable' 'Depends: libc6' | |
15 | ||
16 | setupaptarchive | |
17 | ||
0440d936 | 18 | testsuccess aptget install libc6:i386 -t stable -y |
53ea1b56 | 19 | testdpkginstalled libc6:i386 |
25b86db1 | 20 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
21 | Building dependency tree... |
22 | Reading state information... | |
23 | The following packages will be REMOVED: | |
24 | libc6 | |
25 | The following NEW packages will be installed: | |
26 | libc6:amd64 | |
27 | 0 upgraded, 1 newly installed, 1 to remove and 0 not upgraded. | |
28 | Remv libc6 [1.0] | |
29 | Inst libc6:amd64 (1.0 stable [amd64]) | |
30 | Conf libc6:amd64 (1.0 stable [amd64])' aptget install libc6:amd64 -s -t stable | |
31 | ||
25b86db1 | 32 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
33 | Building dependency tree... |
34 | Reading state information... | |
35 | The following NEW packages will be installed: | |
36 | foobar | |
37 | 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. | |
38 | Inst foobar (1.0 stable [i386]) | |
39 | Conf foobar (1.0 stable [i386])' aptget install foobar -st stable | |
40 | ||
25b86db1 | 41 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
42 | Building dependency tree... |
43 | Reading state information... | |
e7ebb414 | 44 | The following additional packages will be installed: |
6a910c9d DK |
45 | libc6:amd64 |
46 | The following packages will be REMOVED: | |
47 | libc6 | |
48 | The following NEW packages will be installed: | |
49 | foobar:amd64 libc6:amd64 | |
50 | 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded. | |
51 | Remv libc6 [1.0] | |
52 | Inst libc6:amd64 (1.0 stable [amd64]) | |
53 | Inst foobar:amd64 (1.0 stable [amd64]) | |
54 | Conf libc6:amd64 (1.0 stable [amd64]) | |
55 | Conf foobar:amd64 (1.0 stable [amd64])' aptget install foobar:amd64 -st stable | |
56 | ||
25b86db1 | 57 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
58 | Building dependency tree... |
59 | Reading state information... | |
6a910c9d | 60 | The following NEW packages will be installed: |
28166356 DK |
61 | foobar |
62 | The following packages will be upgraded: | |
63 | libc6 | |
64 | 1 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. | |
ca238ede | 65 | Inst libc6 [1.0] (2.0 testing [all]) |
6a910c9d | 66 | Inst foobar (1.0 stable [i386]) |
ca238ede | 67 | Conf libc6 (2.0 testing [all]) |
6a910c9d DK |
68 | Conf foobar (1.0 stable [i386])' aptget install foobar/stable libc6 -st testing |
69 | ||
25b86db1 | 70 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
71 | Building dependency tree... |
72 | Reading state information... | |
2a884c61 | 73 | Calculating upgrade... |
28166356 | 74 | The following packages will be upgraded: |
6a910c9d | 75 | libc6 |
28166356 | 76 | 1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. |
ca238ede DK |
77 | Inst libc6 [1.0] (2.0 testing [all]) |
78 | Conf libc6 (2.0 testing [all])' aptget upgrade -t testing -s | |
53ea1b56 DK |
79 | # FIXME: on amd64 systems this test wouldn't run with a real upgrade |
80 | # as APT (here i386) disagree about the native architecture, so | |
81 | # we fake it here: | |
7a2690a3 | 82 | #aptget upgrade -y -qq >/dev/null 2>&1 |
0440d936 DK |
83 | testsuccess aptget purge libc6 -y |
84 | testsuccess aptget install libc6:i386 -y | |
53ea1b56 | 85 | testdpkginstalled libc6:all |
6a910c9d | 86 | |
25b86db1 | 87 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
88 | Building dependency tree... |
89 | Reading state information... | |
90 | The following NEW packages will be installed: | |
91 | foobar | |
92 | 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. | |
28166356 | 93 | Inst foobar (1.0 stable [i386]) |
6a910c9d DK |
94 | Conf foobar (1.0 stable [i386])' aptget install foobar/stable -st testing |
95 | ||
25b86db1 | 96 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
97 | Building dependency tree... |
98 | Reading state information... | |
e7ebb414 | 99 | The following additional packages will be installed: |
28166356 DK |
100 | libc6:amd64 |
101 | The following packages will be REMOVED: | |
102 | libc6 | |
6a910c9d | 103 | The following NEW packages will be installed: |
28166356 DK |
104 | foobar:amd64 libc6:amd64 |
105 | 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded. | |
106 | Remv libc6 [2.0] | |
107 | Inst libc6:amd64 (1.0 stable [amd64]) | |
6a910c9d | 108 | Inst foobar:amd64 (1.0 stable [amd64]) |
28166356 | 109 | Conf libc6:amd64 (1.0 stable [amd64]) |
6a910c9d DK |
110 | Conf foobar:amd64 (1.0 stable [amd64])' aptget install foobar:amd64/stable -st testing |
111 | ||
112 | ||
25b86db1 | 113 | testsuccessequal "Reading package lists... |
6a910c9d DK |
114 | Building dependency tree... |
115 | Reading state information... | |
116 | Selected version '1.0' (stable [i386]) for 'libc6' | |
28166356 | 117 | The following packages will be DOWNGRADED: |
6a910c9d | 118 | libc6 |
28166356 DK |
119 | 0 upgraded, 0 newly installed, 1 downgraded, 0 to remove and 0 not upgraded. |
120 | Inst libc6 [2.0] (1.0 stable [i386]) | |
6a910c9d DK |
121 | Conf libc6 (1.0 stable [i386])" aptget install libc6/stable -s -q=0 |
122 | ||
123 | ||
124 | buildsimplenativepackage 'libc6-same' 'i386' '1.0' 'stable' 'Multi-Arch: same' | |
125 | buildsimplenativepackage 'libc6-same' 'amd64' '1.0' 'stable' 'Multi-Arch: same' | |
126 | buildsimplenativepackage 'libc6-same' 'all' '2.0' 'testing' | |
127 | ||
128 | buildsimplenativepackage 'foobar-same' 'i386' '1.0' 'stable' 'Depends: libc6-same' | |
129 | buildsimplenativepackage 'foobar-same' 'amd64' '1.0' 'stable' 'Depends: libc6-same' | |
130 | ||
131 | setupaptarchive | |
132 | ||
0440d936 | 133 | testsuccess aptget install libc6-same:i386 -t stable -y |
53ea1b56 | 134 | testdpkginstalled libc6-same:i386 |
6a910c9d | 135 | |
25b86db1 | 136 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
137 | Building dependency tree... |
138 | Reading state information... | |
139 | The following NEW packages will be installed: | |
140 | foobar-same | |
141 | 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. | |
142 | Inst foobar-same (1.0 stable [i386]) | |
143 | Conf foobar-same (1.0 stable [i386])' aptget install foobar-same -st stable | |
144 | ||
25b86db1 | 145 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
146 | Building dependency tree... |
147 | Reading state information... | |
e7ebb414 | 148 | The following additional packages will be installed: |
6a910c9d DK |
149 | libc6-same:amd64 |
150 | The following NEW packages will be installed: | |
151 | foobar-same:amd64 libc6-same:amd64 | |
152 | 0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded. | |
153 | Inst libc6-same:amd64 (1.0 stable [amd64]) | |
154 | Inst foobar-same:amd64 (1.0 stable [amd64]) | |
155 | Conf libc6-same:amd64 (1.0 stable [amd64]) | |
156 | Conf foobar-same:amd64 (1.0 stable [amd64])' aptget install foobar-same:amd64 -st stable | |
157 | ||
25b86db1 | 158 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
159 | Building dependency tree... |
160 | Reading state information... | |
161 | The following NEW packages will be installed: | |
162 | libc6-same:amd64 | |
163 | 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. | |
164 | Inst libc6-same:amd64 (1.0 stable [amd64]) | |
165 | Conf libc6-same:amd64 (1.0 stable [amd64])' aptget install libc6-same:amd64 -s -t stable | |
166 | ||
167 | # FIXME: We should test installing libc6-same:amd64 here, but dpkg doesn't allow it currently | |
168 | ||
25b86db1 | 169 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
170 | Building dependency tree... |
171 | Reading state information... | |
2a884c61 | 172 | Calculating upgrade... |
28166356 | 173 | The following packages will be upgraded: |
6a910c9d | 174 | libc6-same |
28166356 | 175 | 1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. |
ca238ede DK |
176 | Inst libc6-same [1.0] (2.0 testing [all]) |
177 | Conf libc6-same (2.0 testing [all])' aptget upgrade -t testing -s | |
53ea1b56 DK |
178 | # FIXME: on amd64 systems this test wouldn't run with a real upgrade |
179 | # as APT (here i386) disagree about the native architecture, so | |
180 | # we fake it here: | |
7a2690a3 | 181 | #aptget upgrade -y -qq >/dev/null 2>&1 |
0440d936 DK |
182 | testsuccess aptget purge libc6-same -y |
183 | testsuccess aptget install libc6-same:i386 -y | |
53ea1b56 DK |
184 | testdpkginstalled libc6-same:all |
185 | ||
6a910c9d | 186 | |
25b86db1 | 187 | testsuccessequal "Reading package lists... |
6a910c9d DK |
188 | Building dependency tree... |
189 | Reading state information... | |
190 | Selected version '1.0' (stable [i386]) for 'libc6-same' | |
28166356 | 191 | The following packages will be DOWNGRADED: |
6a910c9d | 192 | libc6-same |
28166356 DK |
193 | 0 upgraded, 0 newly installed, 1 downgraded, 0 to remove and 0 not upgraded. |
194 | Inst libc6-same [2.0] (1.0 stable [i386]) | |
6a910c9d DK |
195 | Conf libc6-same (1.0 stable [i386])" aptget install libc6-same/stable -s -q=0 |
196 | ||
25b86db1 | 197 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
198 | Building dependency tree... |
199 | Reading state information... | |
200 | The following NEW packages will be installed: | |
201 | foobar-same | |
202 | 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. | |
28166356 | 203 | Inst foobar-same (1.0 stable [i386]) |
6a910c9d DK |
204 | Conf foobar-same (1.0 stable [i386])' aptget install foobar-same/stable -st testing |
205 | ||
25b86db1 | 206 | testsuccessequal 'Reading package lists... |
6a910c9d DK |
207 | Building dependency tree... |
208 | Reading state information... | |
e7ebb414 | 209 | The following additional packages will be installed: |
28166356 DK |
210 | libc6-same:amd64 |
211 | The following packages will be REMOVED: | |
212 | libc6-same | |
6a910c9d | 213 | The following NEW packages will be installed: |
28166356 DK |
214 | foobar-same:amd64 libc6-same:amd64 |
215 | 0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded. | |
216 | Remv libc6-same [2.0] | |
217 | Inst libc6-same:amd64 (1.0 stable [amd64]) | |
6a910c9d | 218 | Inst foobar-same:amd64 (1.0 stable [amd64]) |
28166356 | 219 | Conf libc6-same:amd64 (1.0 stable [amd64]) |
6a910c9d | 220 | Conf foobar-same:amd64 (1.0 stable [amd64])' aptget install foobar-same:amd64/stable -st testing |