@@ -959,8 +959,14 @@ def retry_handler(_request: httpx.Request) -> httpx.Response:
959959 def test_proxy_environment_variables (self , monkeypatch : pytest .MonkeyPatch ) -> None :
960960 # Test that the proxy environment variables are set correctly
961961 monkeypatch .setenv ("HTTPS_PROXY" , "https://example.org" )
962- # Delete in case our environment has this set
962+ # Delete in case our environment has any proxy env vars set
963963 monkeypatch .delenv ("HTTP_PROXY" , raising = False )
964+ monkeypatch .delenv ("ALL_PROXY" , raising = False )
965+ monkeypatch .delenv ("NO_PROXY" , raising = False )
966+ monkeypatch .delenv ("http_proxy" , raising = False )
967+ monkeypatch .delenv ("https_proxy" , raising = False )
968+ monkeypatch .delenv ("all_proxy" , raising = False )
969+ monkeypatch .delenv ("no_proxy" , raising = False )
964970
965971 client = DefaultHttpxClient ()
966972
@@ -1873,8 +1879,14 @@ async def test_get_platform(self) -> None:
18731879 async def test_proxy_environment_variables (self , monkeypatch : pytest .MonkeyPatch ) -> None :
18741880 # Test that the proxy environment variables are set correctly
18751881 monkeypatch .setenv ("HTTPS_PROXY" , "https://example.org" )
1876- # Delete in case our environment has this set
1882+ # Delete in case our environment has any proxy env vars set
18771883 monkeypatch .delenv ("HTTP_PROXY" , raising = False )
1884+ monkeypatch .delenv ("ALL_PROXY" , raising = False )
1885+ monkeypatch .delenv ("NO_PROXY" , raising = False )
1886+ monkeypatch .delenv ("http_proxy" , raising = False )
1887+ monkeypatch .delenv ("https_proxy" , raising = False )
1888+ monkeypatch .delenv ("all_proxy" , raising = False )
1889+ monkeypatch .delenv ("no_proxy" , raising = False )
18781890
18791891 client = DefaultAsyncHttpxClient ()
18801892
0 commit comments