MCPcopy Index your code
hub / github.com/pre-commit/pre-commit / test_integration_os_environ

Function test_integration_os_environ

tests/envcontext_test.py:98–103  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

96
97
98def test_integration_os_environ():
99 with mock.patch.dict(os.environ, {'FOO': 'bar'}, clear=True):
100 assert os.environ == {'FOO': 'bar'}
101 with envcontext((('HERP', 'derp'),)):
102 assert os.environ == {'FOO': 'bar', 'HERP': 'derp'}
103 assert os.environ == {'FOO': 'bar'}

Callers

nothing calls this directly

Calls 1

envcontextFunction · 0.90

Tested by

no test coverage detected