MCPcopy
hub / github.com/pytest-dev/pytest / test_funcarg_basic

Method test_funcarg_basic

testing/python/fixtures.py:155–164  ·  view source on GitHub ↗
(self, pytester: Pytester)

Source from the content-addressed store, hash-verified

153 )
154
155 def test_funcarg_basic(self, pytester: Pytester) -> None:
156 pytester.copy_example()
157 item = pytester.getitem(Path("test_funcarg_basic.py"))
158 assert isinstance(item, Function)
159 # Execute's item's setup, which fills fixtures.
160 item.session._setupstate.setup(item)
161 del item.funcargs["request"]
162 assert len(get_public_names(item.funcargs)) == 2
163 assert item.funcargs["some"] == "test_func"
164 assert item.funcargs["other"] == 42
165
166 def test_funcarg_lookup_modulelevel(self, pytester: Pytester) -> None:
167 pytester.copy_example()

Callers

nothing calls this directly

Calls 4

get_public_namesFunction · 0.90
copy_exampleMethod · 0.45
getitemMethod · 0.45
setupMethod · 0.45

Tested by

no test coverage detected