MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_read1

Method test_read1

Lib/test/test_lzma.py:997–1003  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

995 self.assertRaises(LZMAError, f.read)
996
997 def test_read1(self):
998 with LZMAFile(BytesIO(COMPRESSED_XZ)) as f:
999 blocks = []
1000 while result := f.read1():
1001 blocks.append(result)
1002 self.assertEqual(b"".join(blocks), INPUT)
1003 self.assertEqual(f.read1(), b"")
1004
1005 def test_read1_0(self):
1006 with LZMAFile(BytesIO(COMPRESSED_XZ)) as f:

Callers

nothing calls this directly

Calls 6

LZMAFileClass · 0.90
BytesIOClass · 0.90
read1Method · 0.45
appendMethod · 0.45
assertEqualMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected