MCPcopy Index your code
hub / github.com/python/cpython / test_issue35753

Method test_issue35753

Lib/test/test_doctest/test_doctest.py:808–816  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

806class TestDocTestFinder(unittest.TestCase):
807
808 def test_issue35753(self):
809 # This import of `call` should trigger issue35753 when
810 # DocTestFinder.find() is called due to inspect.unwrap() failing,
811 # however with a patched doctest this should succeed.
812 from unittest.mock import call
813 dummy_module = types.ModuleType("dummy")
814 dummy_module.__dict__['inject_call'] = call
815 finder = doctest.DocTestFinder()
816 self.assertEqual(finder.find(dummy_module), [])
817
818 def test_empty_namespace_package(self):
819 pkg_name = 'doctest_empty_pkg'

Callers

nothing calls this directly

Calls 2

findMethod · 0.95
assertEqualMethod · 0.45

Tested by

no test coverage detected