(self)
| 59 | self.assertTrue(os.path.isdir(target)) |
| 60 | |
| 61 | def test_overwrite_file_as_dir(self): |
| 62 | target = os.path.join(self.testdir, 'test') |
| 63 | self.create_file(target, b'content') |
| 64 | with self.open(self.ar_with_dir) as ar: |
| 65 | with self.assertRaises(FileExistsError): |
| 66 | self.extractall(ar) |
| 67 | self.assertTrue(os.path.isfile(target)) |
| 68 | with open(target, 'rb') as f: |
| 69 | self.assertEqual(f.read(), b'content') |
| 70 | |
| 71 | def test_overwrite_file_as_implicit_dir(self): |
| 72 | target = os.path.join(self.testdir, 'test') |
nothing calls this directly
no test coverage detected