summaryrefslogtreecommitdiffstats
path: root/test/integration/test-parse-all-archs-into-cache
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-05 18:07:13 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-05 18:07:13 +0000
commit636c7dc17286d93d788c741d15fd756aeda066d5 (patch)
treee7ae158cc54f591041a061b9865bcae51854f15c /test/integration/test-parse-all-archs-into-cache
parentInitial commit. (diff)
downloadapt-upstream/1.8.2.3.tar.xz
apt-upstream/1.8.2.3.zip
Adding upstream version 1.8.2.3.upstream/1.8.2.3upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rwxr-xr-xtest/integration/test-parse-all-archs-into-cache93
1 files changed, 93 insertions, 0 deletions
diff --git a/test/integration/test-parse-all-archs-into-cache b/test/integration/test-parse-all-archs-into-cache
new file mode 100755
index 0000000..7485431
--- /dev/null
+++ b/test/integration/test-parse-all-archs-into-cache
@@ -0,0 +1,93 @@
+#!/bin/sh
+set -e
+
+TESTDIR="$(readlink -f "$(dirname "$0")")"
+. "$TESTDIR/framework"
+setupenvironment
+configarchitecture 'i386'
+
+insertpackage 'unstable' 'bar' 'i386' '1' 'Depends: foo'
+insertpackage 'unstable' 'foo' 'i386' '1' 'Multi-Arch: foreign
+Depends: libfoo1'
+insertpackage 'unstable' 'libfoo1' 'i386' '1' 'Multi-Arch: same'
+insertpackage 'experimental' 'foo' 'i386' '2' 'Multi-Arch: foreign
+Depends: libfoo1 (>= 2)'
+insertpackage 'experimental' 'libfoo1' 'i386' '2' 'Multi-Arch: same'
+
+# note: the system has amd64 not configured!
+insertinstalledpackage 'foo' 'amd64' '1' 'Multi-Arch: foreign
+Depends: libfoo1'
+
+setupaptarchive
+
+testfailureequal "Reading package lists...
+Building dependency tree...
+You might want to run 'apt --fix-broken install' to correct these.
+The following packages have unmet dependencies:
+ foo:amd64 : Depends: libfoo1:amd64 but it is not installable
+E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution)." aptget check -s
+
+insertinstalledpackage 'libfoo1' 'amd64' '1' 'Multi-Arch: same'
+
+testsuccessequal 'Reading package lists...
+Building dependency tree...' aptget check -s
+
+testsuccessequal 'Reading package lists...
+Building dependency tree...
+The following additional packages will be installed:
+ libfoo1
+The following packages will be REMOVED:
+ foo:amd64
+The following NEW packages will be installed:
+ foo libfoo1
+0 upgraded, 2 newly installed, 1 to remove and 0 not upgraded.
+Remv foo:amd64 [1]
+Inst libfoo1 (1 unstable [i386])
+Inst foo (1 unstable [i386])
+Conf libfoo1 (1 unstable [i386])
+Conf foo (1 unstable [i386])' aptget install foo -s
+
+testsuccessequal "Reading package lists...
+Building dependency tree...
+Selected version '2' (experimental [i386]) for 'foo'
+Selected version '2' (experimental [i386]) for 'libfoo1' because of 'foo'
+The following additional packages will be installed:
+ libfoo1
+The following packages will be REMOVED:
+ foo:amd64 libfoo1:amd64
+The following NEW packages will be installed:
+ foo libfoo1
+0 upgraded, 2 newly installed, 2 to remove and 0 not upgraded.
+Remv foo:amd64 [1]
+Remv libfoo1:amd64 [1]
+Inst libfoo1 (2 experimental [i386])
+Inst foo (2 experimental [i386])
+Conf libfoo1 (2 experimental [i386])
+Conf foo (2 experimental [i386])" aptget install foo/experimental -s
+
+testsuccessequal 'Reading package lists...
+Building dependency tree...
+The following additional packages will be installed:
+ foo libfoo1
+The following packages will be REMOVED:
+ foo:amd64
+The following NEW packages will be installed:
+ bar foo libfoo1
+0 upgraded, 3 newly installed, 1 to remove and 0 not upgraded.
+Remv foo:amd64 [1]
+Inst libfoo1 (1 unstable [i386])
+Inst foo (1 unstable [i386])
+Inst bar (1 unstable [i386])
+Conf libfoo1 (1 unstable [i386])
+Conf foo (1 unstable [i386])
+Conf bar (1 unstable [i386])' aptget install bar -s
+
+configarchitecture 'i386' 'amd64'
+
+testsuccessequal 'Reading package lists...
+Building dependency tree...
+The following NEW packages will be installed:
+ bar
+0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
+Inst bar (1 unstable [i386])
+Conf bar (1 unstable [i386])' aptget install bar -s