Skip to content

Commit f5a4d0f

Browse files
committed
chore(ruff): Manual fix for test_config_file
tests/test_config_file.py:197:5: PT012 `pytest.raises()` block should contain a single simple statement
1 parent 59d66dd commit f5a4d0f

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

tests/test_config_file.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -194,11 +194,11 @@ def test_multiple_config_files_raises_exception(tmp_path: pathlib.Path) -> None:
194194
json_conf_file.touch()
195195
yaml_conf_file = tmp_path / ".vcspull.yaml"
196196
yaml_conf_file.touch()
197-
with EnvironmentVarGuard() as env, pytest.raises(exc.MultipleConfigWarning):
198-
env.set("HOME", str(tmp_path))
199-
assert pathlib.Path.home() == tmp_path
200197

201-
config.find_home_config_files()
198+
with EnvironmentVarGuard() as env:
199+
env.set("HOME", str(tmp_path))
200+
with pytest.raises(exc.MultipleConfigWarning):
201+
config.find_home_config_files()
202202

203203

204204
def test_in_dir(

0 commit comments

Comments
 (0)