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

Method test_setup_function

testing/acceptance_test.py:1054–1065  ·  view source on GitHub ↗
(self, pytester: Pytester, mock_timing)

Source from the content-addressed store, hash-verified

1052 """
1053
1054 def test_setup_function(self, pytester: Pytester, mock_timing) -> None:
1055 pytester.makepyfile(self.source)
1056 result = pytester.runpytest_inprocess("--durations=10")
1057 assert result.ret == 0
1058
1059 result.stdout.fnmatch_lines_random(
1060 """
1061 *durations*
1062 5.00s call *test_1*
1063 2.00s setup *test_1*
1064 """
1065 )
1066
1067
1068def test_zipimport_hook(pytester: Pytester) -> None:

Callers

nothing calls this directly

Calls 3

fnmatch_lines_randomMethod · 0.80
makepyfileMethod · 0.45
runpytest_inprocessMethod · 0.45

Tested by

no test coverage detected