Skip to content

Commit 514f8e0

Browse files
fixup! Rename variables 'tmpdir'->'tmp_path'
1 parent c9bb4c4 commit 514f8e0

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

testing/test_collection.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ def test_ignored_certain_directories(self, pytester: Pytester) -> None:
136136
ensure_file(tmp_path / ".whatever" / "test_notfound.py")
137137
ensure_file(tmp_path / ".bzr" / "test_notfound.py")
138138
ensure_file(tmp_path / "normal" / "test_found.py")
139-
for x in Path(str(tmp_path)).rglob("test_*.py"):
139+
for x in tmp_path.rglob("test_*.py"):
140140
x.write_text("def test_hello(): pass", "utf-8")
141141

142142
result = pytester.runpytest("--collect-only")
@@ -632,8 +632,7 @@ class Test_getinitialnodes:
632632
def test_global_file(self, pytester: Pytester) -> None:
633633
tmp_path = pytester.path
634634
x = ensure_file(tmp_path / "x.py")
635-
with tmp_path.cwd():
636-
config = pytester.parseconfigure(x)
635+
config = pytester.parseconfigure(x)
637636
col = pytester.getnode(config, x)
638637
assert isinstance(col, pytest.Module)
639638
assert col.name == "x.py"

0 commit comments

Comments
 (0)