summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2020-05-16 11:17:21 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2020-05-18 15:55:36 +0200
commit57df27397b1a10e50d5876482a30b9dedb2ad219 (patch)
tree2a28c6898e1de093414a30e7a4fa94e7fa08f14c /test
parent55d4d1b51c0d2b78b76f2b233714ed3914b695cf (diff)
Propagate protected to already satisfied conflicts
If we propagate protected e.g. due to a user request we should also act upon (at the moment) satisfied negative dependencies so that the resolver knows that installing this package later is not an option. That the problem resolver is trying bad solutions is a bug by itself which existed before and after and should be worked on. Closes: #960705
Diffstat (limited to 'test')
-rwxr-xr-xtest/integration/test-bug-960705-propagate-protected-to-satisfied-conflict31
1 files changed, 31 insertions, 0 deletions
diff --git a/test/integration/test-bug-960705-propagate-protected-to-satisfied-conflict b/test/integration/test-bug-960705-propagate-protected-to-satisfied-conflict
new file mode 100755
index 000000000..4def47400
--- /dev/null
+++ b/test/integration/test-bug-960705-propagate-protected-to-satisfied-conflict
@@ -0,0 +1,31 @@
+#!/bin/sh
+set -e
+
+TESTDIR="$(readlink -f "$(dirname "$0")")"
+. "$TESTDIR/framework"
+setupenvironment
+configarchitecture 'amd64'
+
+insertpackage 'unstable' 'runit-init' 'all' '1' 'Conflicts: systemd-sysv, sysvinit-core, runit-init'
+# note how the rest do not know of runit-init
+insertpackage 'unstable' 'sysvinit-core' 'all' '1' 'Conflicts: systemd-sysv, sysvinit-core'
+insertpackage 'unstable,installed' 'systemd-sysv' 'all' '1' 'Conflicts: systemd-sysv, sysvinit-core'
+insertpackage 'unstable,installed' 'init' 'all' '1' 'Pre-Depends: systemd-sysv | sysvinit-core
+Important: yes'
+
+setupaptarchive
+
+testsuccessequal "Reading package lists...
+Building dependency tree...
+The following packages will be REMOVED:
+ init systemd-sysv
+The following NEW packages will be installed:
+ runit-init
+WARNING: The following essential packages will be removed.
+This should NOT be done unless you know exactly what you are doing!
+ init systemd-sysv (due to init)
+0 upgraded, 1 newly installed, 2 to remove and 0 not upgraded.
+Remv init [1]
+Remv systemd-sysv [1]
+Inst runit-init (1 unstable [all])
+Conf runit-init (1 unstable [all])" apt install runit-init -s