MCPcopy Index your code
hub / github.com/python/cpython / test_seeking_too

Method test_seeking_too

Lib/test/test_io/test_textio.py:616–625  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

614 self.assertEqual(f.readline(), u_suffix)
615
616 def test_seeking_too(self):
617 # Regression test for a specific bug
618 data = b'\xe0\xbf\xbf\n'
619 with self.open(os_helper.TESTFN, "wb") as f:
620 f.write(data)
621 with self.open(os_helper.TESTFN, "r", encoding="utf-8") as f:
622 f._CHUNK_SIZE # Just test that it exists
623 f._CHUNK_SIZE = 2
624 f.readline()
625 f.tell()
626
627 def test_seek_and_tell(self):
628 #Test seek/tell using the StatefulIncrementalDecoder.

Callers

nothing calls this directly

Calls 4

openMethod · 0.45
writeMethod · 0.45
readlineMethod · 0.45
tellMethod · 0.45

Tested by

no test coverage detected