MCPcopy Index your code
hub / github.com/python/cpython / setUp

Method setUp

Lib/test/test_urllib.py:198–204  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

196class ProxyTests(unittest.TestCase):
197
198 def setUp(self):
199 # Records changes to env vars
200 self.env = self.enterContext(os_helper.EnvironmentVarGuard())
201 # Delete all proxy related env vars
202 for k in list(os.environ):
203 if 'proxy' in k.lower():
204 self.env.unset(k)
205
206 def test_getproxies_environment_keep_no_proxies(self):
207 self.env.set('NO_PROXY', 'localhost')

Callers

nothing calls this directly

Calls 4

listClass · 0.85
enterContextMethod · 0.80
unsetMethod · 0.80
lowerMethod · 0.45

Tested by

no test coverage detected