]> git.saurik.com Git - apt.git/blame_incremental - test/integration/test-apt-acquire-additional-files-duplicates
show apt-key warnings in apt update
[apt.git] / test / integration / test-apt-acquire-additional-files-duplicates
... / ...
CommitLineData
1#!/bin/sh
2set -e
3
4TESTDIR="$(readlink -f "$(dirname "$0")")"
5. "$TESTDIR/framework"
6setupenvironment
7configarchitecture 'amd64' 'i386'
8
9cat > rootdir/etc/apt/apt.conf.d/content-target.conf <<EOF
10Acquire::IndexTargets::deb::Contents1 {
11 MetaKey "\$(COMPONENT)/Contents-\$(ARCHITECTURE)";
12 ShortDescription "Contents";
13 Description "\$(RELEASE) Contents";
14 DefaultEnabled "false";
15};
16Acquire::IndexTargets::deb::Contents2 {
17 MetaKey "\$(COMPONENT)/Contents-\$(ARCHITECTURE)";
18 ShortDescription "Contents";
19 Description "\$(RELEASE) Contents";
20 DefaultEnabled "false";
21};
22Acquire::IndexTargets::deb::Contentsflat {
23 MetaKey "Contents-\$(ARCHITECTURE)";
24 ShortDescription "Contents";
25 Description "\$(RELEASE) Contents";
26 DefaultEnabled "false";
27};
28EOF
29
30mkdir -p ./rootdir/var/lib/apt/lists
31APTLISTS="$(readlink -f ./rootdir/var/lib/apt/lists)"
32APTETC="$(readlink -f ./rootdir/etc/apt)"
33cat > rootdir/etc/apt/sources.list <<EOF
34deb http://example.org/debian stable main rocks
35deb-src http://example.org/debian stable main rocks
36EOF
37testsuccessequal "${APTLISTS}/example.org_debian_dists_stable_main_source_Sources
38${APTLISTS}/example.org_debian_dists_stable_rocks_source_Sources
39${APTLISTS}/example.org_debian_dists_stable_main_binary-amd64_Packages
40${APTLISTS}/example.org_debian_dists_stable_main_binary-i386_Packages
41${APTLISTS}/example.org_debian_dists_stable_main_binary-all_Packages
42${APTLISTS}/example.org_debian_dists_stable_main_i18n_Translation-en
43${APTLISTS}/example.org_debian_dists_stable_rocks_binary-amd64_Packages
44${APTLISTS}/example.org_debian_dists_stable_rocks_binary-i386_Packages
45${APTLISTS}/example.org_debian_dists_stable_rocks_binary-all_Packages
46${APTLISTS}/example.org_debian_dists_stable_rocks_i18n_Translation-en" aptget indextargets --no-release-info --format '$(FILENAME)'
47
48cat >> rootdir/etc/apt/sources.list <<EOF
49deb http://example.org/debian stable main rocks
50EOF
51rm -r rootdir/var/cache/apt/*.bin
52testwarning aptcache gencaches
53testwarningequal "${APTLISTS}/example.org_debian_dists_stable_main_source_Sources
54${APTLISTS}/example.org_debian_dists_stable_rocks_source_Sources
55${APTLISTS}/example.org_debian_dists_stable_main_binary-amd64_Packages
56${APTLISTS}/example.org_debian_dists_stable_main_binary-i386_Packages
57${APTLISTS}/example.org_debian_dists_stable_main_binary-all_Packages
58${APTLISTS}/example.org_debian_dists_stable_main_i18n_Translation-en
59${APTLISTS}/example.org_debian_dists_stable_rocks_binary-amd64_Packages
60${APTLISTS}/example.org_debian_dists_stable_rocks_binary-i386_Packages
61${APTLISTS}/example.org_debian_dists_stable_rocks_binary-all_Packages
62${APTLISTS}/example.org_debian_dists_stable_rocks_i18n_Translation-en
63W: Target Packages (main/binary-amd64/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
64W: Target Packages (main/binary-i386/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
65W: Target Packages (main/binary-all/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
66W: Target Translations (main/i18n/Translation-en) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
67W: Target Packages (rocks/binary-amd64/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
68W: Target Packages (rocks/binary-i386/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
69W: Target Packages (rocks/binary-all/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
70W: Target Translations (rocks/i18n/Translation-en) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3" aptget indextargets --no-release-info --format '$(FILENAME)'
71
72cat >> rootdir/etc/apt/sources.list <<EOF
73deb [target=Contents1,Contents2,Contentsflat arch=amd64] http://example.org/debian stable main rocks
74deb-src [target=Contents1,Contents2,Contentsflat arch=amd64] http://example.org/debian stable main rocks
75EOF
76rm -r rootdir/var/cache/apt/*.bin
77testwarning aptcache gencaches
78testwarningequal "${APTLISTS}/example.org_debian_dists_stable_main_source_Sources
79${APTLISTS}/example.org_debian_dists_stable_rocks_source_Sources
80${APTLISTS}/example.org_debian_dists_stable_main_binary-amd64_Packages
81${APTLISTS}/example.org_debian_dists_stable_main_binary-i386_Packages
82${APTLISTS}/example.org_debian_dists_stable_main_binary-all_Packages
83${APTLISTS}/example.org_debian_dists_stable_main_i18n_Translation-en
84${APTLISTS}/example.org_debian_dists_stable_rocks_binary-amd64_Packages
85${APTLISTS}/example.org_debian_dists_stable_rocks_binary-i386_Packages
86${APTLISTS}/example.org_debian_dists_stable_rocks_binary-all_Packages
87${APTLISTS}/example.org_debian_dists_stable_rocks_i18n_Translation-en
88${APTLISTS}/example.org_debian_dists_stable_main_Contents-amd64
89${APTLISTS}/example.org_debian_dists_stable_main_Contents-all
90${APTLISTS}/example.org_debian_dists_stable_Contents-amd64
91${APTLISTS}/example.org_debian_dists_stable_Contents-all
92${APTLISTS}/example.org_debian_dists_stable_rocks_Contents-amd64
93${APTLISTS}/example.org_debian_dists_stable_rocks_Contents-all
94W: Target Packages (main/binary-amd64/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
95W: Target Packages (main/binary-i386/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
96W: Target Packages (main/binary-all/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
97W: Target Translations (main/i18n/Translation-en) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
98W: Target Packages (rocks/binary-amd64/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
99W: Target Packages (rocks/binary-i386/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
100W: Target Packages (rocks/binary-all/Packages) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
101W: Target Translations (rocks/i18n/Translation-en) is configured multiple times in ${APTETC}/sources.list:1 and ${APTETC}/sources.list:3
102W: Target Contents2 wants to acquire the same file (main/Contents-amd64) as Contents1 from source ${APTETC}/sources.list:4
103W: Target Contents2 wants to acquire the same file (main/Contents-all) as Contents1 from source ${APTETC}/sources.list:4
104W: Target Contents2 wants to acquire the same file (rocks/Contents-amd64) as Contents1 from source ${APTETC}/sources.list:4
105W: Target Contents2 wants to acquire the same file (rocks/Contents-all) as Contents1 from source ${APTETC}/sources.list:4" aptget indextargets --no-release-info --format '$(FILENAME)'