Add exception handling to file cleanup
- Surpress errors caused by long file cleanup in older python environments
This commit is contained in:
parent
922fc0342a
commit
74f2dff57b
|
@ -144,7 +144,10 @@ def longdir(tmp_path):
|
|||
dirname = "\\\\?\\" + str(tmp_path)
|
||||
name = "A" * 100
|
||||
yield op.join(dirname, name, name, name)
|
||||
shutil.rmtree(dirname, ignore_errors=True)
|
||||
try:
|
||||
shutil.rmtree(dirname, ignore_errors=True)
|
||||
except TypeError:
|
||||
pass
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
|
|
Loading…
Reference in New Issue