@@ -967,8 +967,14 @@ def retry_handler(_request: httpx.Request) -> httpx.Response:
967967 def test_proxy_environment_variables (self , monkeypatch : pytest .MonkeyPatch ) -> None :
968968 # Test that the proxy environment variables are set correctly
969969 monkeypatch .setenv ("HTTPS_PROXY" , "https://example.org" )
970- # Delete in case our environment has this set
970+ # Delete in case our environment has any proxy env vars set
971971 monkeypatch .delenv ("HTTP_PROXY" , raising = False )
972+ monkeypatch .delenv ("ALL_PROXY" , raising = False )
973+ monkeypatch .delenv ("NO_PROXY" , raising = False )
974+ monkeypatch .delenv ("http_proxy" , raising = False )
975+ monkeypatch .delenv ("https_proxy" , raising = False )
976+ monkeypatch .delenv ("all_proxy" , raising = False )
977+ monkeypatch .delenv ("no_proxy" , raising = False )
972978
973979 client = DefaultHttpxClient ()
974980
@@ -1889,8 +1895,14 @@ async def test_get_platform(self) -> None:
18891895 async def test_proxy_environment_variables (self , monkeypatch : pytest .MonkeyPatch ) -> None :
18901896 # Test that the proxy environment variables are set correctly
18911897 monkeypatch .setenv ("HTTPS_PROXY" , "https://example.org" )
1892- # Delete in case our environment has this set
1898+ # Delete in case our environment has any proxy env vars set
18931899 monkeypatch .delenv ("HTTP_PROXY" , raising = False )
1900+ monkeypatch .delenv ("ALL_PROXY" , raising = False )
1901+ monkeypatch .delenv ("NO_PROXY" , raising = False )
1902+ monkeypatch .delenv ("http_proxy" , raising = False )
1903+ monkeypatch .delenv ("https_proxy" , raising = False )
1904+ monkeypatch .delenv ("all_proxy" , raising = False )
1905+ monkeypatch .delenv ("no_proxy" , raising = False )
18941906
18951907 client = DefaultAsyncHttpxClient ()
18961908
0 commit comments