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

Method test_read

Lib/test/test_zipfile/_path/test_path.py:240–246  ·  view source on GitHub ↗
(self, alpharep)

Source from the content-addressed store, hash-verified

238
239 @pass_alpharep
240 def test_read(self, alpharep):
241 root = zipfile.Path(alpharep)
242 a, n, b, g, j = root.iterdir()
243 assert a.read_text(encoding="utf-8") == "content of a"
244 # Also check positional encoding arg (gh-101144).
245 assert a.read_text("utf-8") == "content of a"
246 assert a.read_bytes() == b"content of a"
247
248 @pass_alpharep
249 def test_joinpath(self, alpharep):

Callers

nothing calls this directly

Calls 3

iterdirMethod · 0.95
read_textMethod · 0.45
read_bytesMethod · 0.45

Tested by

no test coverage detected