MCPcopy Create free account
hub / github.com/pallets/flask / FakePath

Class FakePath

tests/test_helpers.py:11–22  ·  view source on GitHub ↗

Fake object to represent a ``PathLike object``. This represents a ``pathlib.Path`` object in python 3. See: https://www.python.org/dev/peps/pep-0519/

Source from the content-addressed store, hash-verified

9
10
11class FakePath:
12 """Fake object to represent a ``PathLike object``.
13
14 This represents a ``pathlib.Path`` object in python 3.
15 See: https://www.python.org/dev/peps/pep-0519/
16 """
17
18 def __init__(self, path):
19 self.path = path
20
21 def __fspath__(self):
22 return self.path
23
24
25class PyBytesIO:

Callers 1

test_static_fileMethod · 0.85

Calls

no outgoing calls

Tested by 1

test_static_fileMethod · 0.68