mirror of
https://github.com/django/django.git
synced 2025-08-04 02:48:35 +00:00
Fixed #21122 -- Improved clean up of test temp directory on Windows
- Fixed test that didn't close the files it opened - Caught and handled exception when temp directory cannot be removed
This commit is contained in:
parent
5381317fe3
commit
978e1351a6
2 changed files with 20 additions and 7 deletions
|
@ -174,3 +174,6 @@ class FileMoveSafeTests(unittest.TestCase):
|
|||
|
||||
# should allow it and continue on if allow_overwrite is True
|
||||
self.assertIsNone(file_move_safe(self.file_a, self.file_b, allow_overwrite=True))
|
||||
|
||||
os.close(handle_a)
|
||||
os.close(handle_b)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue