diff options
author | Michael Vogt <mvo@debian.org> | 2015-08-18 11:57:35 +0200 |
---|---|---|
committer | Michael Vogt <mvo@debian.org> | 2015-08-18 11:57:35 +0200 |
commit | b53c9cea2902572822bbbece5bac236c1bbf846e (patch) | |
tree | 6c6b0524e0971c0623ccbff71383523ee0b2a5cc /test/integration/test-apt-update-file | |
parent | 21248c0f00ee71412dbadc6ebf84011cf974346d (diff) | |
parent | 2a22cd60f04c4291ea9b9b72e15b6d2ec378b001 (diff) |
Merge remote-tracking branch 'upstream/debian/experimental' into feature/srv-records
Diffstat (limited to 'test/integration/test-apt-update-file')
-rwxr-xr-x | test/integration/test-apt-update-file | 29 |
1 files changed, 24 insertions, 5 deletions
diff --git a/test/integration/test-apt-update-file b/test/integration/test-apt-update-file index 1ecf9a38a..94b604f0e 100755 --- a/test/integration/test-apt-update-file +++ b/test/integration/test-apt-update-file @@ -22,14 +22,33 @@ addtrap 'prefix' 'chmod 750 aptarchive/dists/unstable/main/binary-amd64;' chmod 550 aptarchive/dists/unstable/main/binary-amd64 testsuccess aptget update + +# the release files aren't an IMS-hit, but the indexes are +redatereleasefiles '+1 hour' + +# we don't download the index if it isn't updated testsuccess aptget update -o Debug::pkgAcquire::Auth=1 +# file:/ isn't shown in the log, so see if it was downloaded anyhow cp -a rootdir/tmp/testsuccess.output rootdir/tmp/update.output +canary="SHA512:$(bzcat aptarchive/dists/unstable/main/binary-amd64/Packages.bz2 | sha512sum |cut -f1 -d' ')" +testfailure grep -- "$canary" rootdir/tmp/update.output + +testfoo() { + # foo is still available + testsuccess aptget install -s foo + testsuccess aptcache showsrc foo + testsuccess aptget source foo --print-uris +} +testfoo -# ensure that the hash of the uncompressed file was verified even on a local ims hit +# the release file is new again, the index still isn't, but it is somehow gone now from disk +redatereleasefiles '+2 hour' +find rootdir/var/lib/apt/lists -name '*_Packages*' -delete + +testsuccess aptget update -o Debug::pkgAcquire::Auth=1 +# file:/ isn't shown in the log, so see if it was downloaded anyhow +cp -a rootdir/tmp/testsuccess.output rootdir/tmp/update.output canary="SHA512:$(bzcat aptarchive/dists/unstable/main/binary-amd64/Packages.bz2 | sha512sum |cut -f1 -d' ')" testsuccess grep -- "$canary" rootdir/tmp/update.output -# foo is still available -testsuccess aptget install -s foo -testsuccess aptcache showsrc foo -testsuccess aptget source foo --print-uris +testfoo |