davidwegs commented on code in PR #2079:
URL: https://github.com/apache/libcloud/pull/2079#discussion_r2893553275
##########
libcloud/test/test_connection.py:
##########
@@ -104,22 +104,12 @@ def test_parse_proxy_url(self):
)
def test_constructor(self):
- proxy_url = "http://127.0.0.2:3128"
- os.environ["http_proxy"] = proxy_url
- conn = LibcloudConnection(host="localhost", port=80)
- self.assertEqual(conn.proxy_scheme, "http")
- self.assertEqual(conn.proxy_host, "127.0.0.2")
- self.assertEqual(conn.proxy_port, 3128)
- self.assertEqual(
- conn.session.proxies,
- {"http": "http://127.0.0.2:3128", "https":
"http://127.0.0.2:3128"},
- )
Review Comment:
Just added a separate unit test for this. I can't verify it in this one
because the Requests library checks the proxy env variables when processing a
request not when creating a Session.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]