Skip to content
Myr

Clear proxy env vars before every test run (#7423)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Nate Prewitt · committed by GitHub · parent fd62809 · Browse files · 1 file+9 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+9 added−0 removed

  • tests:+9 added−0 removed

1 file+9 added−0 removed

modified:tests/conftest.py+9 added
20 unmodified lines
2122 return inner232425@pytest.fixture(autouse=True)26def clean_proxy_environ(monkeypatch):27 """Remove proxy related environment variables for every test."""28 proxy_vars = ("http_proxy", "https_proxy", "no_proxy", "ftp_proxy", "all_proxy")29 for var in proxy_vars:30 monkeypatch.delenv(var, raising=False)31 monkeypatch.delenv(var.upper(), raising=False)323334@pytest.fixture35def httpbin(httpbin):36 return prepare_url(httpbin)37
30 unmodified lines