MCPcopy Create free account
hub / github.com/pytest-dev/pytest / test_subfactory_missing_funcarg

Method test_subfactory_missing_funcarg

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

Source from the content-addressed store, hash-verified

3272
3273class TestErrors:
3274 def test_subfactory_missing_funcarg(self, pytester: Pytester) -> None:
3275 pytester.makepyfile(
3276 """
3277 import pytest
3278 @pytest.fixture()
3279 def gen(qwe123):
3280 return 1
3281 def test_something(gen):
3282 pass
3283 """
3284 )
3285 result = pytester.runpytest()
3286 assert result.ret != 0
3287 result.stdout.fnmatch_lines(
3288 ["*def gen(qwe123):*", "*fixture*qwe123*not found*", "*1 error*"]
3289 )
3290
3291 def test_issue498_fixture_finalizer_failing(self, pytester: Pytester) -> None:
3292 pytester.makepyfile(

Callers

nothing calls this directly

Calls 3

fnmatch_linesMethod · 0.80
makepyfileMethod · 0.45
runpytestMethod · 0.45

Tested by

no test coverage detected