summaryrefslogtreecommitdiff
path: root/test/integration/test-apt-update-nofallback
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2016-05-04 11:10:08 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2016-05-04 12:12:27 +0200
commit761a5ad2ec07f097b05c32427bd0ebddfd587987 (patch)
tree37601497dbb8dd8b3ec73f3bba7a95bad377a30c /test/integration/test-apt-update-nofallback
parent737ce3135d332e3b6165ac1fac5c68e21ba1bdba (diff)
tests: allow to disable generation of InRelease/Release.gpg file
If the test just signs release files to throw away one of them to test the other, we can just as well save the time and not create it. Git-Dch: Ignore
Diffstat (limited to 'test/integration/test-apt-update-nofallback')
-rwxr-xr-xtest/integration/test-apt-update-nofallback8
1 files changed, 3 insertions, 5 deletions
diff --git a/test/integration/test-apt-update-nofallback b/test/integration/test-apt-update-nofallback
index d9166eefd..4db67ee5d 100755
--- a/test/integration/test-apt-update-nofallback
+++ b/test/integration/test-apt-update-nofallback
@@ -9,8 +9,7 @@ set -e
simulate_mitm_and_inject_evil_package()
{
redatereleasefiles '+1 hour'
- rm -f "$APTARCHIVE/dists/unstable/InRelease"
- rm -f "$APTARCHIVE/dists/unstable/Release.gpg"
+ rm -f "$APTARCHIVE/dists/unstable/InRelease" "$APTARCHIVE/dists/unstable/Release.gpg"
inject_evil_package
}
@@ -126,11 +125,10 @@ test_cve_2012_0214()
listcurrentlistsdirectory > lists.before
# do what CVE-2012-0214 did
- rm "$APTARCHIVE/dists/unstable/InRelease"
- rm "$APTARCHIVE/dists/unstable/Release.gpg"
+ rm "$APTARCHIVE/dists/unstable/InRelease" "$APTARCHIVE/dists/unstable/Release.gpg"
inject_evil_package
# build valid Release file
- aptftparchive -qq release ./aptarchive > aptarchive/dists/unstable/Release
+ aptftparchive -qq release ./aptarchive > aptarchive/dists/unstable/Release
assert_update_is_refused_and_last_good_state_used
testfileequal lists.before "$(listcurrentlistsdirectory)"