testfileequal 'listsdir.lst' "$(listcurrentlistsdirectory)"
# ensure that we still do a hash check for other files on ims hit of Release
- if grep -q '^Hit .* InRelease$' expected.output || ! grep -q '^Ign .* Release\(\.gpg\)\?$' expected.output; then
+ if grep -q '^Hit:[0-9]\+ .* InRelease$' expected.output || ! grep -q '^Ign:[0-9]\+ .* Release\(\.gpg\)\?$' expected.output; then
$TEST aptget update -o Debug::Acquire::gpgv=1
cp rootdir/tmp/${TEST}.output goodsign.output
testfileequal 'listsdir.lst' "$(listcurrentlistsdirectory)"
}
msgmsg 'InRelease'
-EXPECT='Hit http://localhost:8080 unstable InRelease
+EXPECT='Hit:1 http://localhost:8080 unstable InRelease
Reading package lists...'
echo 'Acquire::GzipIndexes "0";' > rootdir/etc/apt/apt.conf.d/02compressindex
runtest
runtest
msgmsg 'Release/Release.gpg'
-EXPECT='Ign http://localhost:8080 unstable InRelease
+EXPECT='Ign:1 http://localhost:8080 unstable InRelease
404 Not Found
-Hit http://localhost:8080 unstable Release
+Hit:2 http://localhost:8080 unstable Release
Reading package lists...'
find aptarchive -name 'InRelease' -delete
echo 'Acquire::GzipIndexes "0";' > rootdir/etc/apt/apt.conf.d/02compressindex
runtest
msgmsg 'Release only'
-EXPECT="Ign http://localhost:8080 unstable InRelease
+EXPECT="Ign:1 http://localhost:8080 unstable InRelease
404 Not Found
-Hit http://localhost:8080 unstable Release
-Ign http://localhost:8080 unstable Release.gpg
+Hit:2 http://localhost:8080 unstable Release
+Ign:3 http://localhost:8080 unstable Release.gpg
404 Not Found
Reading package lists...
W: The data from 'http://localhost:8080 unstable Release' is not signed. Packages from that repository can not be authenticated."
signreleasefiles
msgmsg 'expired InRelease'
-EXPECT='Hit http://localhost:8080 unstable InRelease
+EXPECT='Hit:1 http://localhost:8080 unstable InRelease
E: Release file for http://localhost:8080/dists/unstable/InRelease is expired (invalid since). Updates for this repository will not be applied.'
echo 'Acquire::GzipIndexes "0";' > rootdir/etc/apt/apt.conf.d/02compressindex
runtest 'failure'
runtest 'failure'
msgmsg 'expired Release/Release.gpg'
-EXPECT='Ign http://localhost:8080 unstable InRelease
+EXPECT='Ign:1 http://localhost:8080 unstable InRelease
404 Not Found
-Hit http://localhost:8080 unstable Release
+Hit:2 http://localhost:8080 unstable Release
E: Release file for http://localhost:8080/dists/unstable/Release is expired (invalid since). Updates for this repository will not be applied.'
find aptarchive -name 'InRelease' -delete
echo 'Acquire::GzipIndexes "0";' > rootdir/etc/apt/apt.conf.d/02compressindex
runtest 'failure'
msgmsg 'expired Release only'
-EXPECT="Ign http://localhost:8080 unstable InRelease
+EXPECT="Ign:1 http://localhost:8080 unstable InRelease
404 Not Found
-Hit http://localhost:8080 unstable Release
-Ign http://localhost:8080 unstable Release.gpg
+Hit:2 http://localhost:8080 unstable Release
+Ign:3 http://localhost:8080 unstable Release.gpg
404 Not Found
W: The data from 'http://localhost:8080 unstable Release' is not signed. Packages from that repository can not be authenticated.
E: Release file for http://localhost:8080/dists/unstable/Release is expired (invalid since). Updates for this repository will not be applied."
msgmsg 'no Release at all'
-EXPECT="Ign http://localhost:8080 unstable InRelease
+EXPECT="Ign:1 http://localhost:8080 unstable InRelease
404 Not Found
-Ign http://localhost:8080 unstable Release
+Ign:2 http://localhost:8080 unstable Release
404 Not Found
-Hit http://localhost:8080 unstable/main Sources
-Hit http://localhost:8080 unstable/main amd64 Packages
-Hit http://localhost:8080 unstable/main Translation-en
+Hit:3 http://localhost:8080 unstable/main Sources
+Hit:4 http://localhost:8080 unstable/main amd64 Packages
+Hit:5 http://localhost:8080 unstable/main Translation-en
Reading package lists...
W: The repository 'http://localhost:8080 unstable Release' does not have a Release file. This is deprecated, please contact the owner of the repository."
find aptarchive -name '*Release*' -delete