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

Method test_fileobj

Lib/test/test_tarfile.py:2598–2605  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

2596 self._test(fileobj=fobj)
2597
2598 def test_fileobj(self):
2599 self._create_testtar()
2600 with open(self.tarname, "rb") as fobj:
2601 data = fobj.read()
2602 fobj = io.BytesIO(data)
2603 self._add_testfile(fobj)
2604 fobj.seek(0)
2605 self._test(names=["foo", "bar"], fileobj=fobj)
2606
2607 def test_existing(self):
2608 self._create_testtar()

Callers

nothing calls this directly

Calls 6

readMethod · 0.95
_add_testfileMethod · 0.95
seekMethod · 0.95
_testMethod · 0.95
_create_testtarMethod · 0.80
openFunction · 0.50

Tested by

no test coverage detected