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