X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/20a2b201389092a17763b703039b2e4528234e30..ab5b1d0d31b2fbdc4896f8a107611ff056d6a668:/test/integration/test-bug-673536-pre-depends-breaks-loop

diff --git a/test/integration/test-bug-673536-pre-depends-breaks-loop b/test/integration/test-bug-673536-pre-depends-breaks-loop
index e9d3c4de6..eb47553dc 100755
--- a/test/integration/test-bug-673536-pre-depends-breaks-loop
+++ b/test/integration/test-bug-673536-pre-depends-breaks-loop
@@ -6,18 +6,31 @@ TESTDIR=$(readlink -f $(dirname $0))
 setupenvironment
 configarchitecture 'native'
 
-buildsimplenativepackage 'basic' 'native' '1' 'stable'
+buildsimplenativepackage 'advanced' 'native' '1' 'stable'
+buildsimplenativepackage 'advanced' 'native' '2' 'unstable' 'Pre-Depends: basic'
 buildsimplenativepackage 'basic' 'native' '2' 'unstable' 'Pre-Depends: common'
-buildsimplenativepackage 'common' 'native' '2' 'unstable' 'Breaks: basic (<= 1)'
+
+buildsimplenativepackage 'common' 'native' '2~conflict' 'unstable-conflict' 'Conflicts: advanced (<= 1)'
+buildsimplenativepackage 'common' 'native' '2~break' 'unstable-break' 'Conflicts: advanced (<= 1)'
 
 setupaptarchive
 
 # we check with 'real' packages here as the simulation reports a 'Conf broken'
 # which is technical correct for the simulation, but testing errormsg is ugly
 
-aptget install basic=1 -qq > /dev/null
-testdpkginstalled basic
-testdpkgnotinstalled common
+cp -a rootdir/var/lib/dpkg/status dpkg.status.backup
+
+testloopbreak() {
+	cp -a dpkg.status.backup rootdir/var/lib/dpkg/status
+	rm -f rootdir/var/lib/apt/extended_states
+
+	testsuccess aptget install advanced=1 -y -t "$1"
+	testdpkginstalled advanced
+	testdpkgnotinstalled basic common
+
+	testsuccess aptget dist-upgrade -y -t "$1"
+	testdpkginstalled advanced basic common
+}
 
-aptget dist-upgrade -qq > /dev/null
-testdpkginstalled basic common
+testloopbreak 'unstable-break'
+testloopbreak 'unstable-conflict'