File: test-resolver-provider-exchange

package info (click to toggle)
apt 3.1.13
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 22,764 kB
  • sloc: cpp: 71,085; sh: 31,750; xml: 5,553; perl: 217; python: 197; ansic: 191; makefile: 41
file content (142 lines) | stat: -rwxr-xr-x 4,848 bytes parent folder | download | duplicates (2)
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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
#!/bin/sh
set -e

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

insertinstalledpackage 'fuse' 'all' '2'
insertpackage 'unstable' 'fuse' 'all' '2'
insertpackage 'unstable' 'fuse3' 'all' '3' 'Conflicts: fuse
Provides: fuse'

insertpackage 'unstable' 'foobar-d' 'all' '1' 'Depends: fuse'
insertpackage 'unstable' 'foobar-d2' 'all' '1' 'Depends: fuse
Conflicts: fuse3'
insertpackage 'unstable' 'foobar-d3' 'all' '1' 'Depends: fuse3'
insertpackage 'unstable' 'foobar-r' 'all' '1' 'Recommends: fuse'
insertpackage 'unstable' 'foobar-r2' 'all' '1' 'Recommends: fuse
Conflicts: fuse3'
insertpackage 'unstable' 'foobar-r3' 'all' '1' 'Recommends: fuse3'

setupaptarchive
testsuccess aptmark auto ~i

installfoobars() {
	testsuccessequal 'Reading package lists...
Building dependency tree...
Reading state information...
The following NEW packages will be installed:
  foobar-d
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Inst foobar-d (1 unstable [all])
Conf foobar-d (1 unstable [all])' apt install -s foobar-d
	testsuccessequal 'Reading package lists...
Building dependency tree...
Reading state information...
The following NEW packages will be installed:
  foobar-d2
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Inst foobar-d2 (1 unstable [all])
Conf foobar-d2 (1 unstable [all])' apt install -s foobar-d2
	testsuccessequal "Reading package lists...
Building dependency tree...
Reading state information...
The following additional packages will be installed:
  fuse3
The following packages will be REMOVED:
  fuse
The following NEW packages will be installed:
  foobar-d3 fuse3
0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
Remv fuse [2]$1
Inst fuse3 (3 unstable [all])
Inst foobar-d3 (1 unstable [all])
Conf fuse3 (3 unstable [all])
Conf foobar-d3 (1 unstable [all])" apt install -s foobar-d3

	testsuccessequal 'Reading package lists...
Building dependency tree...
Reading state information...
The following NEW packages will be installed:
  foobar-r
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Inst foobar-r (1 unstable [all])
Conf foobar-r (1 unstable [all])' apt install -s foobar-r
	testsuccessequal 'Reading package lists...
Building dependency tree...
Reading state information...
The following NEW packages will be installed:
  foobar-r2
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Inst foobar-r2 (1 unstable [all])
Conf foobar-r2 (1 unstable [all])' apt install -s foobar-r2
	if [ -z "$1" ]; then
		testsuccessequal "Reading package lists...
Building dependency tree...
Reading state information...
The following additional packages will be installed:
  fuse3
The following packages will be REMOVED:
  fuse
The following NEW packages will be installed:
  foobar-r3 fuse3
0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
Remv fuse [2]$1
Inst foobar-r3 (1 unstable [all])
Inst fuse3 (3 unstable [all])
Conf foobar-r3 (1 unstable [all])
Conf fuse3 (3 unstable [all])" apt install -s foobar-r3
		testsuccessequal "Reading package lists...
Building dependency tree...
Reading state information...
The following additional packages will be installed:
  fuse3
The following packages will be REMOVED:
  fuse
The following NEW packages will be installed:
  foobar-r3 fuse3
0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
Remv fuse [2]$1
Inst foobar-r3 (1 unstable [all])
Inst fuse3 (3 unstable [all])
Conf foobar-r3 (1 unstable [all])
Conf fuse3 (3 unstable [all])" apt install -s foobar-r3
	else
		testsuccessequal "Reading package lists...
Building dependency tree...
Reading state information...
The following additional packages will be installed:
  fuse3
The following packages will be REMOVED:
  fuse
The following NEW packages will be installed:
  foobar-r3 fuse3
0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
Remv fuse [2]$1
Inst fuse3 (3 unstable [all])
Inst foobar-r3 (1 unstable [all])
Conf fuse3 (3 unstable [all])
Conf foobar-r3 (1 unstable [all])" apt install -s foobar-r3 --solver internal
	testsuccessequal "Reading package lists...
Building dependency tree...
Reading state information...
Solving dependencies...
Recommended packages:
  fuse3
The following NEW packages will be installed:
  foobar-r3
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Inst foobar-r3 (1 unstable [all])
Conf foobar-r3 (1 unstable [all])" apt install -s foobar-r3 --solver 3.0
	fi
}
msgmsg 'fuse has no installed dependers'
installfoobars

for i in $(seq 0 10); do
	insertinstalledpackage "stuff$i" 'all' '1' 'Depends: fuse'
done
msgmsg 'fuse has many dependers installed'
installfoobars ' [stuff0:amd64 stuff1:amd64 stuff2:amd64 stuff3:amd64 stuff4:amd64 stuff5:amd64 stuff6:amd64 stuff7:amd64 stuff8:amd64 stuff9:amd64 stuff10:amd64 ]'