MCPcopy
hub / github.com/pytest-dev/pytest / test_with_non_dir_arg

Method test_with_non_dir_arg

testing/test_config.py:2107–2119  ·  view source on GitHub ↗
(
        self, dirs: Sequence[str], tmp_path: Path, monkeypatch: MonkeyPatch
    )

Source from the content-addressed store, hash-verified

2105
2106 @pytest.mark.parametrize("dirs", ([], ["does-not-exist"], ["a/does-not-exist"]))
2107 def test_with_non_dir_arg(
2108 self, dirs: Sequence[str], tmp_path: Path, monkeypatch: MonkeyPatch
2109 ) -> None:
2110 monkeypatch.chdir(tmp_path)
2111 rootpath, inipath, *_ = determine_setup(
2112 inifile=None,
2113 override_ini=None,
2114 args=dirs,
2115 rootdir_cmd_arg=None,
2116 invocation_dir=Path.cwd(),
2117 )
2118 assert rootpath == tmp_path
2119 assert inipath is None
2120
2121 def test_with_existing_file_in_subdir(
2122 self, tmp_path: Path, monkeypatch: MonkeyPatch

Callers

nothing calls this directly

Calls 2

determine_setupFunction · 0.90
chdirMethod · 0.45

Tested by

no test coverage detected