mirror of
https://github.com/python/cpython.git
synced 2025-08-31 14:07:50 +00:00
Issue #27038: Expose DirEntry as os.DirEntry.
Thanks to Jelle Zijlstra for the code portion of the patch.
This commit is contained in:
parent
620d9c7200
commit
a32c4d0531
4 changed files with 31 additions and 24 deletions
|
@ -2854,6 +2854,7 @@ class TestScandir(unittest.TestCase):
|
|||
self.assertEqual(stat1, stat2)
|
||||
|
||||
def check_entry(self, entry, name, is_dir, is_file, is_symlink):
|
||||
self.assertIsInstance(entry, os.DirEntry)
|
||||
self.assertEqual(entry.name, name)
|
||||
self.assertEqual(entry.path, os.path.join(self.path, name))
|
||||
self.assertEqual(entry.inode(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue