summaryrefslogtreecommitdiffstats
path: root/test/integration/test-not-upgrading-removed-depends
blob: c7d67af3d29a564d0044ff8785e78abb9d59c9de (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
#!/bin/sh
set -e

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

insertpackage 'unstable' 'untouchable-for-solving' 'all' '1' 'Conflicts: main'
insertpackage 'installed' 'bad' 'all' '1' 'Depends: main (= 1)'
insertpackage 'unstable' 'bad' 'all' '2' 'Depends: main (= 2), untouchable-for-solving'

insertpackage 'installed' 'main' 'all' '1'
insertpackage 'unstable' 'main' 'all' '2' 'Breaks: bad'

insertpackage 'unstable' 'else' 'all' '1'
insertpackage 'unstable' 'meta' 'all' '1' 'Depends: main (= 2) | else'

setupaptarchive

testsuccessequal 'Reading package lists...
Building dependency tree...
The following packages will be REMOVED:
  bad
The following packages will be upgraded:
  main
1 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
Remv bad [1]
Inst main [1] (2 unstable [all])
Conf main (2 unstable [all])' apt install -s main
testsuccess apt install -s main -o Debug::pkgProblemResolver=1 -o Debug::pkgDepCache::Marker=1 -o Debug::pkgDepCache::AutoInstall=1
testfailure grep 'untouchable-for-solving' rootdir/tmp/testsuccess.output
testsuccessequal 'Reading package lists...
Building dependency tree...
The following additional packages will be installed:
  main
The following packages will be REMOVED:
  bad
The following NEW packages will be installed:
  meta
The following packages will be upgraded:
  main
1 upgraded, 1 newly installed, 1 to remove and 0 not upgraded.
Remv bad [1]
Inst main [1] (2 unstable [all])
Inst meta (1 unstable [all])
Conf main (2 unstable [all])
Conf meta (1 unstable [all])' apt install -s meta
testsuccess apt install -s meta -o Debug::pkgProblemResolver=1 -o Debug::pkgDepCache::Marker=1 -o Debug::pkgDepCache::AutoInstall=1
testfailure grep 'untouchable-for-solving' rootdir/tmp/testsuccess.output