summaryrefslogtreecommitdiff
path: root/test/integration/test-apt-helper
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2015-03-10 00:59:44 +0100
committerDavid Kalnischkies <david@kalnischkies.de>2015-03-16 18:01:54 +0100
commit25b86db159fbc3c043628e285c0c1ef24dec2c6e (patch)
treeeee3860a1a0ff542959db83dcf8e7ffafad91bf1 /test/integration/test-apt-helper
parentb209edfa318e89df31a2dcae82c3d72b48c1e77f (diff)
test exitcode as well as string equality
We use test{success,failure} now all over the place in the framework, so its only consequencial to do this in the situations in which we test for a specific output as well. Git-Dch: Ignore
Diffstat (limited to 'test/integration/test-apt-helper')
-rwxr-xr-xtest/integration/test-apt-helper14
1 files changed, 7 insertions, 7 deletions
diff --git a/test/integration/test-apt-helper b/test/integration/test-apt-helper
index ff5d506b5..431210797 100755
--- a/test/integration/test-apt-helper
+++ b/test/integration/test-apt-helper
@@ -44,7 +44,7 @@ E: Download Failed'
test_apt_helper_detect_proxy() {
# no proxy
- testequal "Using proxy '' for URL 'http://example.com/'" apthelper auto-detect-proxy http://example.com/
+ testsuccessequal "Using proxy '' for URL 'http://example.com/'" apthelper auto-detect-proxy http://example.com/
# http auto detect proxy script
@@ -55,7 +55,7 @@ EOF
chmod 755 apt-proxy-detect
echo "Acquire::http::Proxy-Auto-Detect \"$(pwd)/apt-proxy-detect\";" > rootdir/etc/apt/apt.conf.d/02proxy-detect
- testequal "Using proxy 'http://some-proxy' for URL 'http://www.example.com/'" apthelper auto-detect-proxy http://www.example.com
+ testsuccessequal "Using proxy 'http://some-proxy' for URL 'http://www.example.com/'" apthelper auto-detect-proxy http://www.example.com
# https auto detect proxy script
@@ -66,14 +66,14 @@ EOF
chmod 755 apt-proxy-detect
echo "Acquire::https::Proxy-Auto-Detect \"$(pwd)/apt-proxy-detect\";" > rootdir/etc/apt/apt.conf.d/02proxy-detect
- testequal "Using proxy 'https://https-proxy' for URL 'https://ssl.example.com/'" apthelper auto-detect-proxy https://ssl.example.com
+ testsuccessequal "Using proxy 'https://https-proxy' for URL 'https://ssl.example.com/'" apthelper auto-detect-proxy https://ssl.example.com
}
test_apt_helper_download
test_apt_helper_detect_proxy
# test failure modes
-testequal 'E: Invalid operation download' apthelper download
-testequal 'E: Must specify at least one pair url/filename' apthelper download-file
-testequal 'E: Must specify at least one pair url/filename' apthelper download-file http://example.org/
-testequal 'E: Need one URL as argument' apthelper auto-detect-proxy
+testfailureequal 'E: Invalid operation download' apthelper download
+testfailureequal 'E: Must specify at least one pair url/filename' apthelper download-file
+testfailureequal 'E: Must specify at least one pair url/filename' apthelper download-file http://example.org/
+testfailureequal 'E: Need one URL as argument' apthelper auto-detect-proxy