MCPcopy Create free account
hub / github.com/pytest-dev/pytest / test_validate_basetemp_fails

Function test_validate_basetemp_fails

testing/test_main.py:94–100  ·  view source on GitHub ↗
(tmp_path, basetemp, monkeypatch)

Source from the content-addressed store, hash-verified

92
93@pytest.mark.parametrize("basetemp", ["", ".", ".."])
94def test_validate_basetemp_fails(tmp_path, basetemp, monkeypatch):
95 monkeypatch.chdir(str(tmp_path))
96 msg = "basetemp must not be empty, the current working directory or any parent directory of it"
97 with pytest.raises(argparse.ArgumentTypeError, match=msg):
98 if basetemp:
99 basetemp = tmp_path / basetemp
100 validate_basetemp(basetemp)
101
102
103def test_validate_basetemp_integration(pytester: Pytester) -> None:

Callers

nothing calls this directly

Calls 2

validate_basetempFunction · 0.90
chdirMethod · 0.45

Tested by

no test coverage detected