(self)
| 1654 | |
| 1655 | @contextmanager |
| 1656 | def prepare(self): |
| 1657 | TestPosixDirFd.count += 1 |
| 1658 | name = f'{os_helper.TESTFN}_{self.count}' |
| 1659 | base_dir = f'{os_helper.TESTFN}_{self.count}base' |
| 1660 | posix.mkdir(base_dir) |
| 1661 | self.addCleanup(posix.rmdir, base_dir) |
| 1662 | fullname = os.path.join(base_dir, name) |
| 1663 | assert not os.path.exists(fullname) |
| 1664 | with os_helper.open_dir_fd(base_dir) as dir_fd: |
| 1665 | yield (dir_fd, name, fullname) |
| 1666 | |
| 1667 | @contextmanager |
| 1668 | def prepare_file(self): |
no test coverage detected