File tree 1 file changed +3
-5
lines changed
1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -740,15 +740,13 @@ class TestDocTestFinder(unittest.TestCase):
740
740
741
741
def test_issue35753 (self ):
742
742
# This import of `call` should trigger issue35753 when
743
- # `support.run_doctest` is called due to unwrap failing,
743
+ # DocTestFinder.find() is called due to inspect. unwrap() failing,
744
744
# however with a patched doctest this should succeed.
745
745
from unittest .mock import call
746
746
dummy_module = types .ModuleType ("dummy" )
747
747
dummy_module .__dict__ ['inject_call' ] = call
748
- try :
749
- support .run_doctest (dummy_module , verbosity = True )
750
- except ValueError as e :
751
- raise support .TestFailed ("Doctest unwrap failed" ) from e
748
+ finder = doctest .DocTestFinder ()
749
+ self .assertEqual (finder .find (dummy_module ), [])
752
750
753
751
def test_empty_namespace_package (self ):
754
752
pkg_name = 'doctest_empty_pkg'
You can’t perform that action at this time.
0 commit comments