Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Update tests
  • Loading branch information
uriyyo committed Jul 8, 2021
commit b92ba0d9c73df7c8fea504fee4a19acfe020e3b0
2 changes: 1 addition & 1 deletion Lib/test/ann_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,4 +59,4 @@ def wrapper(*args, **kwargs):
return func(*args, **kwargs)
return wrapper

core_union: int | float
u: int | float
2 changes: 1 addition & 1 deletion Lib/test/test_grammar.py
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ class CC(metaclass=CMeta):
def test_var_annot_module_semantics(self):
self.assertEqual(test.__annotations__, {})
self.assertEqual(ann_module.__annotations__,
{1: 2, 'x': int, 'y': str, 'f': typing.Tuple[int, int]})
{1: 2, 'x': int, 'y': str, 'f': typing.Tuple[int, int], 'u': int | float})
self.assertEqual(ann_module.M.__annotations__,
{'123': 123, 'o': type})
self.assertEqual(ann_module2.__annotations__, {})
Expand Down
2 changes: 1 addition & 1 deletion Lib/test/test_typing.py
Original file line number Diff line number Diff line change
Expand Up @@ -2863,7 +2863,7 @@ def test_get_type_hints_from_various_objects(self):
gth(None)

def test_get_type_hints_modules(self):
ann_module_type_hints = {1: 2, 'f': Tuple[int, int], 'x': int, 'y': str, 'core_union': int | float}
ann_module_type_hints = {1: 2, 'f': Tuple[int, int], 'x': int, 'y': str, 'u': int | float}
self.assertEqual(gth(ann_module), ann_module_type_hints)
self.assertEqual(gth(ann_module2), {})
self.assertEqual(gth(ann_module3), {})
Expand Down