Skip to content

Commit 40feee5

Browse files
committed
Close the file before copying to it.
1 parent d3f9bfc commit 40feee5

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

tests/_test_tools.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ def _deploy(path: Union[Path, str]) -> Iterator[Path]:
6767
path = Path(path)
6868
with tempfile.NamedTemporaryFile(dir=Path.home() / '.psij' / 'test', delete=False) as df:
6969
try:
70+
df.close()
7071
shutil.copyfile(path, df.name)
7172
yield Path(df.name)
7273
finally:

0 commit comments

Comments
 (0)