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