File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change 4444import weakref
4545import types
4646
47- from test .support import captured_stderr , cpython_only
47+ from test .support import captured_stderr , cpython_only , infinite_recursion
4848from test import mod_generics_cache
4949from test import _typed_dict_helper
5050
@@ -5622,10 +5622,11 @@ def fun(x: a): pass
56225622 def cmp (o1 , o2 ):
56235623 return o1 == o2
56245624
5625- r1 = namespace1 ()
5626- r2 = namespace2 ()
5627- self .assertIsNot (r1 , r2 )
5628- self .assertRaises (RecursionError , cmp , r1 , r2 )
5625+ with infinite_recursion (25 ): # magic number, small but reasonable
5626+ r1 = namespace1 ()
5627+ r2 = namespace2 ()
5628+ self .assertIsNot (r1 , r2 )
5629+ self .assertRaises (RecursionError , cmp , r1 , r2 )
56295630
56305631 def test_union_forward_recursion (self ):
56315632 ValueList = List ['Value' ]
You can’t perform that action at this time.
0 commit comments