summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorJulian Andres Klode <jak@debian.org>2025-11-10 10:30:49 +0000
committerJulian Andres Klode <jak@debian.org>2025-11-10 10:30:49 +0000
commitd44dc9a5ed0b0a9491a9cee62cfcc6b6f1a54690 (patch)
treea353edee9682acad458a5b3746533d0d09054449 /test
parent4ff117ecbd2173747da90d387abafa1a56675b55 (diff)
parent2f4299bf39c85b694876cb8030fae0887e8b5edc (diff)
Merge branch 'bug1120463' into 'main'
Correctly copy provided version in m-a lazy-init See merge request apt-team/apt!530
Diffstat (limited to 'test')
-rwxr-xr-xtest/integration/test-bug-1120463-multi-arch-provides-version24
1 files changed, 24 insertions, 0 deletions
diff --git a/test/integration/test-bug-1120463-multi-arch-provides-version b/test/integration/test-bug-1120463-multi-arch-provides-version
new file mode 100755
index 000000000..cd2c6dd33
--- /dev/null
+++ b/test/integration/test-bug-1120463-multi-arch-provides-version
@@ -0,0 +1,24 @@
+#!/bin/sh
+set -e
+
+TESTDIR="$(readlink -f "$(dirname "$0")")"
+. "$TESTDIR/framework"
+
+setupenvironment
+configarchitecture 'amd64' 'i386'
+
+# This first initializes a "dep-virt" provides, but then lazy-inits the
+# dep-virt:amd64 one when this is being used later on.
+# In bug 1120463, we accidentally copied version 1.0 instead of 2.0...
+insertpackage 'unstable' 'dep' 'amd64' '1.0' 'Provides: dep-virt (= 2.0)'
+insertpackage 'unstable' 'app' 'i386' '1.0' 'Depends: dep-virt:amd64 (= 2.0)'
+
+
+setupaptarchive
+
+testsuccess aptcache showpkg dep
+mv rootdir/tmp/testsuccess.output showpkg
+testsuccessequal "Provides:
+1.0 - dep-virt:amd64 (= 2.0) dep-virt (= 2.0) " grep ^Provides -A1 showpkg
+
+