(self)
| 1414 | self.assertEqual(file_data, uncompressed_raw * 2) |
| 1415 | |
| 1416 | def test_filename(self): |
| 1417 | with TempFile(TESTFN): |
| 1418 | with lzma.open(TESTFN, "wb") as f: |
| 1419 | f.write(INPUT) |
| 1420 | with open(TESTFN, "rb") as f: |
| 1421 | file_data = lzma.decompress(f.read()) |
| 1422 | self.assertEqual(file_data, INPUT) |
| 1423 | with lzma.open(TESTFN, "rb") as f: |
| 1424 | self.assertEqual(f.read(), INPUT) |
| 1425 | with lzma.open(TESTFN, "ab") as f: |
| 1426 | f.write(INPUT) |
| 1427 | with lzma.open(TESTFN, "rb") as f: |
| 1428 | self.assertEqual(f.read(), INPUT * 2) |
| 1429 | |
| 1430 | def test_with_pathlike_filename(self): |
| 1431 | filename = FakePath(TESTFN) |
nothing calls this directly
no test coverage detected