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

Method test_failing_import

testing/python/collect.py:19–21  ·  view source on GitHub ↗
(self, pytester: Pytester)

Source from the content-addressed store, hash-verified

17
18class TestModule:
19 def test_failing_import(self, pytester: Pytester) -> None:
20 modcol = pytester.getmodulecol("import alksdjalskdjalkjals")
21 pytest.raises(Collector.CollectError, modcol.collect)
22
23 def test_import_duplicate(self, pytester: Pytester) -> None:
24 a = pytester.mkdir("a")

Callers

nothing calls this directly

Calls 1

getmodulecolMethod · 0.45

Tested by

no test coverage detected