@@ -23,10 +23,7 @@ def get_output(args: list[str]) -> str:
23
23
24
24
25
25
warns_cli_root_override = pytest .warns (
26
- UserWarning , match = "root .. is overridden by the cli arg ."
27
- )
28
- warns_absolute_root_override = pytest .warns (
29
- UserWarning , match = "absolute root path '.*' overrides relative_to '.*'"
26
+ UserWarning , match = "root .. is overridden by the cli arg .*"
30
27
)
31
28
32
29
exits_with_not_found = pytest .raises (SystemExit , match = "no version found for" )
@@ -35,11 +32,9 @@ def get_output(args: list[str]) -> str:
35
32
def test_cli_find_pyproject (
36
33
wd : WorkDir , monkeypatch : pytest .MonkeyPatch , debug_mode : DebugMode
37
34
) -> None :
38
- debug_mode .disable ()
39
35
wd .commit_testfile ()
40
36
wd .write (PYPROJECT_TOML , PYPROJECT_SIMPLE )
41
37
monkeypatch .chdir (wd .cwd )
42
-
43
38
out = get_output ([])
44
39
assert out .startswith ("0.1.dev1+" )
45
40
@@ -50,7 +45,7 @@ def test_cli_find_pyproject(
50
45
with exits_with_not_found :
51
46
print (get_output (["-c" , PYPROJECT_TOML ]))
52
47
53
- with exits_with_not_found , warns_absolute_root_override :
48
+ with warns_cli_root_override , exits_with_not_found :
54
49
get_output (["-c" , PYPROJECT_TOML , "--root=.." ])
55
50
56
51
with warns_cli_root_override :
0 commit comments