summaryrefslogtreecommitdiff
path: root/test/integration/test-apt-install-order-matters-a-bit
blob: e41709ff3d2d897a4b4a82b6c21ad7d54ddb3895 (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
#!/bin/sh
set -e

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

insertpackage 'unstable' 'a' 'all' '1' 'Depends: b | d'
insertpackage 'unstable' 'b' 'all' '1'
insertpackage 'unstable' 'c' 'all' '1' 'Depends: d | b'
insertpackage 'unstable' 'd' 'all' '1'

setupaptarchive

testsuccessequal 'Reading package lists...
Building dependency tree...
The following additional packages will be installed:
  b
The following NEW packages will be installed:
  a b c
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Inst b (1 unstable [all])
Inst a (1 unstable [all])
Inst c (1 unstable [all])
Conf b (1 unstable [all])
Conf a (1 unstable [all])
Conf c (1 unstable [all])' apt install a c -s
testsuccessequal 'Reading package lists...
Building dependency tree...
The following additional packages will be installed:
  d
The following NEW packages will be installed:
  a c d
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Inst d (1 unstable [all])
Inst a (1 unstable [all])
Inst c (1 unstable [all])
Conf d (1 unstable [all])
Conf a (1 unstable [all])
Conf c (1 unstable [all])' apt install c a -s

TOPLEVELCHOICE='Reading package lists...
Building dependency tree...
The following NEW packages will be installed:
  a c d
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Inst d (1 unstable [all])
Inst a (1 unstable [all])
Inst c (1 unstable [all])
Conf d (1 unstable [all])
Conf a (1 unstable [all])
Conf c (1 unstable [all])'
testsuccessequal "$TOPLEVELCHOICE" apt install d a c -s
testsuccessequal "$TOPLEVELCHOICE" apt install a c d -s

testsuccessequal 'Reading package lists...
Building dependency tree...
  MarkInstall a:amd64 < none -> 1 @un puN Ib > FU=1
    MarkInstall b:amd64 < none -> 1 @un uN > FU=0
  MarkInstall c:amd64 < none -> 1 @un puN > FU=1
Starting pkgProblemResolver with broken count: 0
Starting 2 pkgProblemResolver with broken count: 0
Done
The following additional packages will be installed:
  b
The following NEW packages will be installed:
  a b c
0 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Inst b (1 unstable [all])
Inst a (1 unstable [all])
Inst c (1 unstable [all])
Conf b (1 unstable [all])
Conf a (1 unstable [all])
Conf c (1 unstable [all])' apt install a a a c a a a -s -o Debug::pkgProblemResolver=1 -o Debug::pkgDepCache::Marker=1