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

Method test_write_sequential

Lib/test/test_tempfile.py:1285–1295  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1283 self.assertFalse(f._rolled)
1284
1285 def test_write_sequential(self):
1286 # A SpooledTemporaryFile should hold exactly max_size bytes, and roll
1287 # over afterward
1288 f = self.do_create(max_size=30)
1289 self.assertFalse(f._rolled)
1290 f.write(b'x' * 20)
1291 self.assertFalse(f._rolled)
1292 f.write(b'x' * 10)
1293 self.assertFalse(f._rolled)
1294 f.write(b'x')
1295 self.assertTrue(f._rolled)
1296
1297 def test_writelines(self):
1298 # Verify writelines with a SpooledTemporaryFile

Callers

nothing calls this directly

Calls 4

do_createMethod · 0.95
assertFalseMethod · 0.80
assertTrueMethod · 0.80
writeMethod · 0.45

Tested by

no test coverage detected