]> git.saurik.com Git - apt.git/blob - test/integration/test-bug-758153-versioned-provides-support
require explicit paths to dsc/control as we do for deb files
[apt.git] / test / integration / test-bug-758153-versioned-provides-support
1 #!/bin/sh
2 set -e
3
4 # dpkg implements versioned provides in commit 5bb02fe80e9f40dcad9703a72f67cf615ff217b5
5 # but previous versions seem to allow parsing, working and ignoring it.
6
7 TESTDIR=$(readlink -f $(dirname $0))
8 . $TESTDIR/framework
9 setupenvironment
10 configarchitecture 'amd64' 'i386'
11
12 insertinstalledpackage 'webapp' 'all' '1' 'Depends: httpd'
13 insertinstalledpackage 'webserver' 'all' '1' 'Provides: httpd'
14
15 insertpackage 'unstable' 'webapp' 'all' '2' 'Depends: httpd (>= 2)'
16 insertpackage 'unstable' 'webserver' 'amd64' '2' 'Provides: httpd (= 2)'
17 insertpackage 'unstable' 'foreign-webserver' 'i386' '2' 'Multi-Arch: foreign
18 Provides: httpd (= 2)'
19
20 insertpackage 'experimental' 'webapp' 'all' '3' 'Depends: httpd (>= 1.5)'
21 insertpackage 'experimental' 'webserver' 'amd64' '3' 'Provides: httpd (= 3)'
22
23 insertpackage 'experimental' 'foreign-webserver' 'i386' '4' 'Multi-Arch: foreign
24 Provides: httpd (= 4)'
25 insertpackage 'experimental' 'cool-webapp' 'all' '4' 'Depends: httpd (>= 4)'
26
27 # arch-qualified provides, see #777071
28 insertpackage 'unstable' 'foo' 'all' '1' 'Provides: bar:i386'
29 insertpackage 'unstable' 'baz' 'i386,amd64' '1' 'Depends: bar'
30 insertpackage 'experimental' 'baz' 'i386,amd64' '2' 'Depends: bar:i386'
31 insertpackage 'experimental' 'baz-broken' 'i386' '2' 'Depends: bar:amd64'
32
33 insertpackage 'unstable' 'next' 'amd64' '1' 'Multi-Arch: foreign
34 Provides: next (= 2)'
35 insertpackage 'unstable' 'needsrealnext' 'amd64,i386' '2' 'Depends: next (>= 2)'
36
37 insertpackage 'unstable' 'virtualnext2' 'amd64' '1' 'Multi-Arch: foreign
38 Provides: next2 (= 2)'
39 insertpackage 'unstable' 'needsnext2' 'amd64,i386' '2' 'Depends: next2 (>= 2)'
40
41 insertpackage 'unstable' 'virtualnext3' 'amd64' '1' 'Multi-Arch: no
42 Provides: next3 (= 2)'
43 insertpackage 'unstable' 'needsnext3' 'amd64,i386' '2' 'Depends: next3 (>= 2)'
44
45 insertpackage 'unstable' 'selfprov' 'amd64' '2' 'Provides: selfprov (= 1)'
46 insertpackage 'unstable' 'needsselfprov1' 'amd64' '1' 'Depends: selfprov (= 1)'
47 insertpackage 'unstable' 'needsselfprov2' 'amd64' '1' 'Depends: selfprov (= 2)'
48 insertpackage 'unstable' 'needsselfprov12' 'amd64' '1' 'Depends: selfprov (= 1), selfprov (= 2)'
49 insertpackage 'unstable' 'needsselfprov123' 'amd64' '1' 'Depends: selfprov (= 1), selfprov (= 2), selfprov (= 3)'
50
51 setupaptarchive
52
53 testsuccessequal 'Reading package lists...
54 Building dependency tree...
55 Calculating upgrade...
56 The following packages will be upgraded:
57 webapp webserver
58 2 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
59 Inst webserver [1] (2 unstable [amd64])
60 Inst webapp [1] (2 unstable [all])
61 Conf webserver (2 unstable [amd64])
62 Conf webapp (2 unstable [all])' aptget dist-upgrade -s
63
64 testsuccessequal 'Reading package lists...
65 Building dependency tree...
66 The following packages will be upgraded:
67 webapp webserver
68 2 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
69 Inst webserver [1] (2 unstable [amd64])
70 Inst webapp [1] (2 unstable [all])
71 Conf webserver (2 unstable [amd64])
72 Conf webapp (2 unstable [all])' aptget install webapp webserver -s
73
74 testsuccessequal 'Reading package lists...
75 Building dependency tree...
76 The following packages will be upgraded:
77 webapp webserver
78 2 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
79 Inst webserver [1] (2 unstable [amd64])
80 Inst webapp [1] (3 experimental [all])
81 Conf webserver (2 unstable [amd64])
82 Conf webapp (3 experimental [all])' aptget install webapp=3 webserver -s
83
84 testsuccessequal 'Reading package lists...
85 Building dependency tree...
86 The following packages will be upgraded:
87 webapp webserver
88 2 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
89 Inst webserver [1] (3 experimental [amd64])
90 Inst webapp [1] (2 unstable [all])
91 Conf webserver (3 experimental [amd64])
92 Conf webapp (2 unstable [all])' aptget install webapp webserver=3 -s
93
94 testsuccessequal 'Reading package lists...
95 Building dependency tree...
96 The following NEW packages will be installed:
97 foreign-webserver:i386
98 The following packages will be upgraded:
99 webapp
100 1 upgraded, 1 newly installed, 0 to remove and 1 not upgraded.
101 Inst foreign-webserver:i386 (2 unstable [i386])
102 Inst webapp [1] (2 unstable [all])
103 Conf foreign-webserver:i386 (2 unstable [i386])
104 Conf webapp (2 unstable [all])' aptget install webapp foreign-webserver:i386 -s
105
106 testsuccessequal 'Reading package lists...
107 Building dependency tree...
108 The following NEW packages will be installed:
109 foreign-webserver:i386
110 The following packages will be upgraded:
111 webapp
112 1 upgraded, 1 newly installed, 0 to remove and 1 not upgraded.
113 Inst foreign-webserver:i386 (2 unstable [i386])
114 Inst webapp [1] (3 experimental [all])
115 Conf foreign-webserver:i386 (2 unstable [i386])
116 Conf webapp (3 experimental [all])' aptget install webapp=3 foreign-webserver:i386 -s
117
118 testsuccessequal 'Reading package lists...
119 Building dependency tree...
120 The following NEW packages will be installed:
121 foreign-webserver:i386
122 The following packages will be upgraded:
123 webapp
124 1 upgraded, 1 newly installed, 0 to remove and 1 not upgraded.
125 Inst foreign-webserver:i386 (4 experimental [i386])
126 Inst webapp [1] (2 unstable [all])
127 Conf foreign-webserver:i386 (4 experimental [i386])
128 Conf webapp (2 unstable [all])' aptget install webapp foreign-webserver:i386=4 -s
129
130 testfailureequal 'Reading package lists...
131 Building dependency tree...
132 Some packages could not be installed. This may mean that you have
133 requested an impossible situation or if you are using the unstable
134 distribution that some required packages have not yet been created
135 or been moved out of Incoming.
136 The following information may help to resolve the situation:
137
138 The following packages have unmet dependencies:
139 cool-webapp : Depends: httpd (>= 4)
140 E: Unable to correct problems, you have held broken packages.' aptget install cool-webapp -s
141
142 testfailureequal 'Reading package lists...
143 Building dependency tree...
144 Some packages could not be installed. This may mean that you have
145 requested an impossible situation or if you are using the unstable
146 distribution that some required packages have not yet been created
147 or been moved out of Incoming.
148 The following information may help to resolve the situation:
149
150 The following packages have unmet dependencies:
151 cool-webapp : Depends: httpd (>= 4)
152 E: Unable to correct problems, you have held broken packages.' aptget install cool-webapp foreign-webserver:i386 -s
153
154 testsuccessequal 'Reading package lists...
155 Building dependency tree...
156 The following NEW packages will be installed:
157 cool-webapp foreign-webserver:i386
158 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
159 Inst foreign-webserver:i386 (4 experimental [i386])
160 Inst cool-webapp (4 experimental [all])
161 Conf foreign-webserver:i386 (4 experimental [i386])
162 Conf cool-webapp (4 experimental [all])' aptget install cool-webapp foreign-webserver:i386=4 -s
163
164 testsuccessequal 'Reading package lists...
165 Building dependency tree...
166 The following additional packages will be installed:
167 foo
168 The following NEW packages will be installed:
169 baz:i386 foo
170 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
171 Inst foo (1 unstable [all])
172 Inst baz:i386 (1 unstable [i386])
173 Conf foo (1 unstable [all])
174 Conf baz:i386 (1 unstable [i386])' aptget install baz:i386 -s
175
176 testfailureequal 'Reading package lists...
177 Building dependency tree...
178 Some packages could not be installed. This may mean that you have
179 requested an impossible situation or if you are using the unstable
180 distribution that some required packages have not yet been created
181 or been moved out of Incoming.
182 The following information may help to resolve the situation:
183
184 The following packages have unmet dependencies:
185 baz : Depends: bar but it is not installable
186 E: Unable to correct problems, you have held broken packages.' aptget install baz:amd64 -s
187
188 testsuccessequal "Reading package lists...
189 Building dependency tree...
190 Selected version '2' (experimental [amd64]) for 'baz'
191 The following additional packages will be installed:
192 foo
193 The following NEW packages will be installed:
194 baz foo
195 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
196 Inst foo (1 unstable [all])
197 Inst baz (2 experimental [amd64])
198 Conf foo (1 unstable [all])
199 Conf baz (2 experimental [amd64])" aptget install baz/experimental -s
200
201 testsuccessequal "Reading package lists...
202 Building dependency tree...
203 Selected version '2' (experimental [i386]) for 'baz:i386'
204 The following additional packages will be installed:
205 foo
206 The following NEW packages will be installed:
207 baz:i386 foo
208 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
209 Inst foo (1 unstable [all])
210 Inst baz:i386 (2 experimental [i386])
211 Conf foo (1 unstable [all])
212 Conf baz:i386 (2 experimental [i386])" aptget install baz:i386/experimental -s
213
214 testfailureequal 'Reading package lists...
215 Building dependency tree...
216 Some packages could not be installed. This may mean that you have
217 requested an impossible situation or if you are using the unstable
218 distribution that some required packages have not yet been created
219 or been moved out of Incoming.
220 The following information may help to resolve the situation:
221
222 The following packages have unmet dependencies:
223 baz-broken:i386 : Depends: bar:amd64 but it is not installable
224 E: Unable to correct problems, you have held broken packages.' aptget install baz-broken -s
225
226 testsuccessequal 'Reading package lists...
227 Building dependency tree...
228 The following additional packages will be installed:
229 next
230 The following NEW packages will be installed:
231 needsrealnext next
232 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
233 Inst next (1 unstable [amd64])
234 Inst needsrealnext (2 unstable [amd64])
235 Conf next (1 unstable [amd64])
236 Conf needsrealnext (2 unstable [amd64])' aptget install needsrealnext -s
237
238 testsuccessequal 'Reading package lists...
239 Building dependency tree...
240 The following additional packages will be installed:
241 next
242 The following NEW packages will be installed:
243 needsrealnext:i386 next
244 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
245 Inst next (1 unstable [amd64])
246 Inst needsrealnext:i386 (2 unstable [i386])
247 Conf next (1 unstable [amd64])
248 Conf needsrealnext:i386 (2 unstable [i386])' aptget install needsrealnext:i386 -s
249
250 testsuccessequal 'Reading package lists...
251 Building dependency tree...
252 The following additional packages will be installed:
253 virtualnext2
254 The following NEW packages will be installed:
255 needsnext2 virtualnext2
256 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
257 Inst virtualnext2 (1 unstable [amd64])
258 Inst needsnext2 (2 unstable [amd64])
259 Conf virtualnext2 (1 unstable [amd64])
260 Conf needsnext2 (2 unstable [amd64])' aptget install needsnext2 -s
261
262 testsuccessequal 'Reading package lists...
263 Building dependency tree...
264 The following additional packages will be installed:
265 virtualnext2
266 The following NEW packages will be installed:
267 needsnext2:i386 virtualnext2
268 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
269 Inst virtualnext2 (1 unstable [amd64])
270 Inst needsnext2:i386 (2 unstable [i386])
271 Conf virtualnext2 (1 unstable [amd64])
272 Conf needsnext2:i386 (2 unstable [i386])' aptget install needsnext2:i386 -s
273
274 testsuccessequal 'Reading package lists...
275 Building dependency tree...
276 The following additional packages will be installed:
277 virtualnext3
278 The following NEW packages will be installed:
279 needsnext3 virtualnext3
280 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
281 Inst virtualnext3 (1 unstable [amd64])
282 Inst needsnext3 (2 unstable [amd64])
283 Conf virtualnext3 (1 unstable [amd64])
284 Conf needsnext3 (2 unstable [amd64])' aptget install needsnext3 -s
285
286 testfailureequal 'Reading package lists...
287 Building dependency tree...
288 Some packages could not be installed. This may mean that you have
289 requested an impossible situation or if you are using the unstable
290 distribution that some required packages have not yet been created
291 or been moved out of Incoming.
292 The following information may help to resolve the situation:
293
294 The following packages have unmet dependencies:
295 needsnext3:i386 : Depends: next3:i386 (>= 2) but it is not installable
296 E: Unable to correct problems, you have held broken packages.' aptget install needsnext3:i386 -s
297
298 testsuccessequal 'Reading package lists...
299 Building dependency tree...
300 The following additional packages will be installed:
301 selfprov
302 The following NEW packages will be installed:
303 needsselfprov1 selfprov
304 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
305 Inst selfprov (2 unstable [amd64])
306 Inst needsselfprov1 (1 unstable [amd64])
307 Conf selfprov (2 unstable [amd64])
308 Conf needsselfprov1 (1 unstable [amd64])' aptget install needsselfprov1 -s
309 testsuccessequal 'Reading package lists...
310 Building dependency tree...
311 The following additional packages will be installed:
312 selfprov
313 The following NEW packages will be installed:
314 needsselfprov2 selfprov
315 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
316 Inst selfprov (2 unstable [amd64])
317 Inst needsselfprov2 (1 unstable [amd64])
318 Conf selfprov (2 unstable [amd64])
319 Conf needsselfprov2 (1 unstable [amd64])' aptget install needsselfprov2 -s
320 testsuccessequal 'Reading package lists...
321 Building dependency tree...
322 The following additional packages will be installed:
323 selfprov
324 The following NEW packages will be installed:
325 needsselfprov12 selfprov
326 0 upgraded, 2 newly installed, 0 to remove and 2 not upgraded.
327 Inst selfprov (2 unstable [amd64])
328 Inst needsselfprov12 (1 unstable [amd64])
329 Conf selfprov (2 unstable [amd64])
330 Conf needsselfprov12 (1 unstable [amd64])' aptget install needsselfprov12 -s
331 testfailureequal 'Reading package lists...
332 Building dependency tree...
333 Some packages could not be installed. This may mean that you have
334 requested an impossible situation or if you are using the unstable
335 distribution that some required packages have not yet been created
336 or been moved out of Incoming.
337 The following information may help to resolve the situation:
338
339 The following packages have unmet dependencies:
340 needsselfprov123 : Depends: selfprov (= 3)
341 E: Unable to correct problems, you have held broken packages.' aptget install needsselfprov123 -s