mirror of
https://github.com/python/cpython.git
synced 2025-11-01 10:45:30 +00:00
merge
This commit is contained in:
commit
8c18da20f9
5 changed files with 32 additions and 3 deletions
|
|
@ -39,6 +39,13 @@ class FileCompareTestCase(unittest.TestCase):
|
|||
self.assertFalse(filecmp.cmp(self.name, self.dir),
|
||||
"File and directory compare as equal")
|
||||
|
||||
def test_cache_clear(self):
|
||||
first_compare = filecmp.cmp(self.name, self.name_same, shallow=False)
|
||||
second_compare = filecmp.cmp(self.name, self.name_diff, shallow=False)
|
||||
filecmp.clear_cache()
|
||||
self.assertTrue(len(filecmp._cache) == 0,
|
||||
"Cache not cleared after calling clear_cache")
|
||||
|
||||
class DirCompareTestCase(unittest.TestCase):
|
||||
def setUp(self):
|
||||
tmpdir = tempfile.gettempdir()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue