From 2ac1942c72fda6d2a1912fb4e8b6ebfc43ee9f30 Mon Sep 17 00:00:00 2001 From: ERAMOTO Masaya Date: Mon, 19 Dec 2016 16:27:24 +0900 Subject: url: --noproxy option overrides NO_PROXY environment variable Under condition using http_proxy env var, noproxy list was the combination of --noproxy option and NO_PROXY env var previously. Since this commit, --noproxy option overrides NO_PROXY environment variable even if use http_proxy env var. Closes #1140 --- tests/data/test1256 | 54 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 tests/data/test1256 (limited to 'tests/data/test1256') diff --git a/tests/data/test1256 b/tests/data/test1256 new file mode 100644 index 000000000..09c59f4ff --- /dev/null +++ b/tests/data/test1256 @@ -0,0 +1,54 @@ + + + +HTTP +HTTP proxy +NO_PROXY +noproxy + + + +# Server-side + + +HTTP/1.1 200 OK +Date: Thu, 09 Nov 2010 14:49:00 GMT +Server: test-server/fake +Content-Length: 4 +Content-Type: text/html + +foo + + + +# Client-side + + +http + + +Under condition using http_proxy, override NO_PROXY by --nproxy and access target URL through proxy + + +http_proxy=http://%HOSTIP:%HTTPPORT +NO_PROXY=example.com + + +http://somewhere.example.com/1256 --noproxy %HOSTIP + + + +# Verify data after the test has been "shot" + + +^User-Agent:.* + + +GET http://somewhere.example.com/1256 HTTP/1.1 +Host: somewhere.example.com +Accept: */* +Proxy-Connection: Keep-Alive + + + + -- cgit v1.2.3