summaryrefslogtreecommitdiff
path: root/test/integration/test-crossgrades
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2016-11-23 17:32:20 +0100
committerJulian Andres Klode <jak@debian.org>2017-02-22 16:53:45 +0100
commitb75c6dc6018ce22a7419911a66e994e502c4497f (patch)
tree108fe67640fa0ff4aaf9848c15b46d577a3005d5 /test/integration/test-crossgrades
parente66d27ce765ff16afa40bc563601991e198acb18 (diff)
improve arch-unqualified dpkg-progress parsing
Our old idea was to look for the first package which would be "touched" and take this as the package dpkg is talking about, but that is incorrect in complicated situations like a package upgraded to/from multiple M-A:same siblings installed. As we us the progress report to decide what is still needed we have to be reasonabily right about the package dpkg is talking about, so we jump to quite a few loops to get it. (cherry picked from commit 4b10240cca0dc0a4e82e42959545d2ae7e622d29)
Diffstat (limited to 'test/integration/test-crossgrades')
-rwxr-xr-xtest/integration/test-crossgrades13
1 files changed, 11 insertions, 2 deletions
diff --git a/test/integration/test-crossgrades b/test/integration/test-crossgrades
index d412546c1..30195d30f 100755
--- a/test/integration/test-crossgrades
+++ b/test/integration/test-crossgrades
@@ -11,6 +11,7 @@ configdpkgnoopchroot
buildsimplenativepackage 'unrelated' 'amd64' '1' 'stable'
buildsimplenativepackage 'crosser' 'i386,armel' '1' 'stable' 'Multi-Arch: same'
buildsimplenativepackage 'crosser' 'amd64' '2' 'unstable'
+buildsimplenativepackage 'crosser' 'i386,armel' '3' 'experimental' 'Multi-Arch: same'
setupaptarchive
singleinstance() {
@@ -43,7 +44,15 @@ multiinstance() {
testdpkgnotinstalled 'crosser:i386' 'crosser:armel' 'unrelated'
testdpkginstalled 'crosser:amd64'
- testsuccess apt purge crosser:amd64 -y --planner $1
- testdpkgnotinstalled 'crosser:amd64'
+ testsuccess apt install crosser:i386 crosser:armel -t experimental -y -o Debug::pkgDpkgPm=1 -o Dpkg::Use-Pty=0 --purge --planner $1
+ cp -a rootdir/tmp/testsuccess.output crosser.output
+ testsuccess grep -- '--remove.*crosser.*' crosser.output
+ testsuccess grep -- '--purge' crosser.output
+ testsuccess apt install crosser:i386 crosser:armel -t experimental -y -o Debug::pkgDPkgProgressReporting=1 -o Dpkg::Use-Pty=0 --purge --planner $1
+ testdpkgnotinstalled 'crosser:amd64' 'unrelated'
+ testdpkginstalled 'crosser:i386' 'crosser:armel'
+
+ testsuccess apt purge crosser:i386 crosser:armel -y --planner $1
+ testdpkgnotinstalled 'crosser:i386' 'crosser:armel' 'unrelated'
}
multiinstance 'internal'