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

Method test_no_under

testing/test_collection.py:863–874  ·  view source on GitHub ↗
(self, pytester: Pytester)

Source from the content-addressed store, hash-verified

861
862class TestNodeKeywords:
863 def test_no_under(self, pytester: Pytester) -> None:
864 modcol = pytester.getmodulecol(
865 """
866 def test_pass(): pass
867 def test_fail(): assert 0
868 """
869 )
870 values = list(modcol.keywords)
871 assert modcol.name in values
872 for x in values:
873 assert not x.startswith("_")
874 assert modcol.name in repr(modcol.keywords)
875
876 def test_issue345(self, pytester: Pytester) -> None:
877 pytester.makepyfile(

Callers

nothing calls this directly

Calls 1

getmodulecolMethod · 0.45

Tested by

no test coverage detected