@@ -4516,19 +4516,14 @@ def test_builtins_have_signatures(self):
4516
4516
# These have unrepresentable parameter default values of NULL
4517
4517
needs_null = {"anext" }
4518
4518
no_signature |= needs_null
4519
- # These need PEP 457 groups or a signature change to accept None
4520
- needs_semantic_update = {"round" }
4521
- no_signature |= needs_semantic_update
4522
4519
# These need *args support in Argument Clinic
4523
- needs_varargs = {"breakpoint" , "min" , "max" , "print" ,
4524
- "__build_class__" }
4520
+ needs_varargs = {"breakpoint" , "min" , "max" , "__build_class__" }
4525
4521
no_signature |= needs_varargs
4526
- # These simply weren't covered in the initial AC conversion
4527
- # for builtin callables
4528
- not_converted_yet = {"open" , "__import__" }
4529
- no_signature |= not_converted_yet
4530
4522
# These builtin types are expected to provide introspection info
4531
- types_with_signatures = set ()
4523
+ types_with_signatures = {
4524
+ 'complex' , 'enumerate' , 'float' , 'list' , 'memoryview' , 'object' ,
4525
+ 'property' , 'reversed' , 'tuple' ,
4526
+ }
4532
4527
# Check the signatures we expect to be there
4533
4528
ns = vars (builtins )
4534
4529
for name , obj in sorted (ns .items ()):
@@ -4547,9 +4542,9 @@ def test_builtins_have_signatures(self):
4547
4542
# This ensures this test will start failing as more signatures are
4548
4543
# added, so the affected items can be moved into the scope of the
4549
4544
# regression test above
4550
- for name in no_signature :
4545
+ for name in no_signature - needs_null - needs_groups :
4551
4546
with self .subTest (builtin = name ):
4552
- self .assertIsNone (obj .__text_signature__ )
4547
+ self .assertIsNone (ns [ name ] .__text_signature__ )
4553
4548
4554
4549
def test_python_function_override_signature (self ):
4555
4550
def func (* args , ** kwargs ):
0 commit comments