(self)
| 1692 | self._test_pathname("///foo", "foo") |
| 1693 | |
| 1694 | def test_cwd(self): |
| 1695 | # Test adding the current working directory. |
| 1696 | with os_helper.change_cwd(TEMPDIR): |
| 1697 | tar = tarfile.open(tmpname, self.mode) |
| 1698 | try: |
| 1699 | tar.add(".") |
| 1700 | finally: |
| 1701 | tar.close() |
| 1702 | |
| 1703 | tar = tarfile.open(tmpname, "r") |
| 1704 | try: |
| 1705 | for t in tar: |
| 1706 | if t.name != ".": |
| 1707 | self.assertStartsWith(t.name, "./") |
| 1708 | finally: |
| 1709 | tar.close() |
| 1710 | |
| 1711 | def test_open_nonwritable_fileobj(self): |
| 1712 | for exctype in OSError, EOFError, RuntimeError: |
nothing calls this directly
no test coverage detected