From e250df1a623fd08f8a5afe2d94bd29a35e872725 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Tue, 21 Mar 2017 09:27:25 +0100 Subject: Show permission error if ProxyAutoDetect cmd can't be executed MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit As the proxy commands are not executed as root, a user can run into permission errors (s)he isn't expecting – as our switching is an implementation detail – so the error message in that case should really be better than a generic "error code 100" sending the user in the wrong direction as that implies the command was executed, but errored out. Closes: 857885 --- test/integration/test-apt-helper | 2 ++ 1 file changed, 2 insertions(+) (limited to 'test/integration/test-apt-helper') diff --git a/test/integration/test-apt-helper b/test/integration/test-apt-helper index a936243ec..fda28968f 100755 --- a/test/integration/test-apt-helper +++ b/test/integration/test-apt-helper @@ -94,6 +94,8 @@ test_apt_helper_detect_proxy() { W: ProxyAutoDetect command returned an empty line" apthelper auto-detect-proxy http://example.com/ setupproxydetect 'http' 'echo DIRECT' testsuccessequal "Using proxy 'DIRECT' for URL 'http://example.com/'" apthelper auto-detect-proxy http://example.com/ + chmod -x "${TMPWORKINGDIRECTORY}/apt-proxy-detect" + testfailureequal "E: ProxyAutoDetect command '${TMPWORKINGDIRECTORY}/apt-proxy-detect' can not be executed! - access (13: Permission denied)" apthelper auto-detect-proxy http://example.com/ msgmsg "apt-helper $CONFNAME" 'http proxy' setupproxydetect 'http' 'echo "http://some-proxy"' -- cgit v1.2.3