summaryrefslogtreecommitdiff
path: root/test/integration/test-explore-or-groups-in-markinstall
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2020-04-27 13:51:46 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2020-04-27 13:51:46 +0200
commitae23e53f99ea0b7920744a7303fdee64796b7cce (patch)
tree6201c01507e3db1e897918f3b8a03701bbca708f /test/integration/test-explore-or-groups-in-markinstall
parentca14e1e2c3f3c9782f374757ca4605ce7e5670ad (diff)
Protect a package while resolving in MarkInstall
Strange things happen if while resolving the dependencies of a package said dependencies want to remove the package. The allow-scores test e.g. removed the preferred alternative in favor of the last one now that they were exclusive. In our or-group for Recommends we would "just" not statisfy the Recommends and for Depends we engage the ProblemResolver…
Diffstat (limited to 'test/integration/test-explore-or-groups-in-markinstall')
-rwxr-xr-xtest/integration/test-explore-or-groups-in-markinstall14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/integration/test-explore-or-groups-in-markinstall b/test/integration/test-explore-or-groups-in-markinstall
index 259155854..5669e47b3 100755
--- a/test/integration/test-explore-or-groups-in-markinstall
+++ b/test/integration/test-explore-or-groups-in-markinstall
@@ -15,6 +15,10 @@ insertpackage 'unstable' 'bad-level0' 'all' '1' 'Depends: unneeded, unknown'
insertpackage 'unstable' 'bad-level1' 'all' '1' 'Depends: bad-level0'
insertpackage 'unstable' 'bad-upgrade-level0' 'all' '2' 'Depends: unneeded, unknown'
insertpackage 'unstable' 'bad-upgrade-level1' 'all' '2' 'Depends: bad-upgrade-level0 (>= 2)'
+insertpackage 'unstable' 'bad-conflict-level0' 'all' '1' 'Depends: unneeded
+Conflicts: bad-conflict-level2'
+insertpackage 'unstable' 'bad-conflict-level1' 'all' '1' 'Depends: bad-conflict-level0'
+insertpackage 'unstable' 'bad-conflict-level2' 'all' '1' 'Depends: bad-conflict-level1'
insertinstalledpackage 'upgrade' 'all' '1'
insertinstalledpackage 'bad-upgrade' 'all' '1'
@@ -29,6 +33,8 @@ insertfoos() {
insertpackage 'unstable' "foo-${1}-upgrade-level0" 'all' '1' "${2}: bad-upgrade (>= 2) | okay | upgrade (>= 2) | later"
insertpackage 'unstable' "foo-${1}-upgrade-level1" 'all' '1' "${2}: bad-upgrade-level0 (>= 2) | bad-upgrade-level0 (>= 2) | bad-level0 | okay | upgrade (>= 2) | later"
insertpackage 'unstable' "foo-${1}-upgrade-level2" 'all' '1' "${2}: bad-upgrade-level1 (>= 2) | bad-upgrade-level1 (>= 2) | bad-level1 | okay | upgrade (>= 2) | later"
+
+ insertpackage 'unstable' "foo-${1}-conflict" 'all' '1' "${2}: unknown | bad-conflict-level2 | okay | later"
}
insertfoos 'd' 'Depends'
insertfoos 'r' 'Recommends'
@@ -65,6 +71,14 @@ The following packages will be upgraded:
upgrade
1 upgraded, 1 newly installed, 0 to remove and $((2-${level})) not upgraded." apt install foo-${1}-upgrade-level${level} -s
done
+
+ testsuccessheadequal 7 "Reading package lists...
+Building dependency tree...
+The following additional packages will be installed:
+ okay
+The following NEW packages will be installed:
+ foo-${1}-conflict okay
+0 upgraded, 2 newly installed, 0 to remove and 3 not upgraded." apt install foo-${1}-conflict -s
}
checkfoos 'd' 'Depends'
checkfoos 'r' 'Recommends'