summaryrefslogtreecommitdiff
path: root/test/integration/test-apt-update-expected-size
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2015-06-08 15:22:01 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2015-06-09 12:57:36 +0200
commit8d041b4f4f353079268039dcbfd8b5e575196b66 (patch)
treeb7b98628e0ef408ab413aed1665de87f6679c3ce /test/integration/test-apt-update-expected-size
parent9b8c28f430a8fbe73252cc3e87b6e88e9d5063d9 (diff)
do not request files if we expect an IMS hit
If we have a file on disk and the hashes are the same in the new Release file and the old one we have on disk we know that if we ask the server for the file, we will at best get an IMS hit – at worse the server doesn't support this and sends us the (unchanged) file and we have to run all our checks on it again for nothing. So, we can save ourselves (and the servers) some unneeded requests if we figure this out on our own.
Diffstat (limited to 'test/integration/test-apt-update-expected-size')
-rwxr-xr-xtest/integration/test-apt-update-expected-size4
1 files changed, 3 insertions, 1 deletions
diff --git a/test/integration/test-apt-update-expected-size b/test/integration/test-apt-update-expected-size
index 55bba8188..24ca85133 100755
--- a/test/integration/test-apt-update-expected-size
+++ b/test/integration/test-apt-update-expected-size
@@ -26,7 +26,9 @@ test_inreleasetoobig() {
}
test_packagestoobig() {
- redatereleasefiles '+1hour'
+ insertpackage 'unstable' 'foo' 'all' '1.0'
+ buildaptarchivefromfiles '+1 hour'
+ signreleasefiles
# append junk at the end of the Packages.gz/Packages
SIZE="$(stat --printf=%s aptarchive/dists/unstable/main/binary-i386/Packages)"
find aptarchive/dists -name 'Packages*' | while read pkg; do