From 8acf759770746676a1b39876f9f9fe9d26019fb2 Mon Sep 17 00:00:00 2001 From: hauntsaninja <> Date: Sat, 7 Dec 2019 17:56:32 -0800 Subject: [PATCH] TypedDict: update test for changes to keys, values, items The signature of TypedDict's keys, values, items will be updated in typeshed in: https://github.com/python/typeshed/pull/3529 The relevant issue is: https://github.com/python/typeshed/issues/3473 That PR fails testTypedDictMappingMethods https://travis-ci.org/python/typeshed/builds/621439570 Tested by using my patched version of typeshed: ln -sf ~/typeshed mypy/typeshed pytest -n0 -k testTypedDictMappingMethods --- test-data/unit/pythoneval.test | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test-data/unit/pythoneval.test b/test-data/unit/pythoneval.test index d6df7ece9899..59dbc1f97056 100644 --- a/test-data/unit/pythoneval.test +++ b/test-data/unit/pythoneval.test @@ -1117,9 +1117,9 @@ _testTypedDictMappingMethods.py:5: note: Revealed type is 'builtins.str*' _testTypedDictMappingMethods.py:6: note: Revealed type is 'typing.Iterator[builtins.str*]' _testTypedDictMappingMethods.py:7: note: Revealed type is 'builtins.int' _testTypedDictMappingMethods.py:8: note: Revealed type is 'builtins.bool' -_testTypedDictMappingMethods.py:9: note: Revealed type is 'typing.AbstractSet[builtins.str*]' -_testTypedDictMappingMethods.py:10: note: Revealed type is 'typing.AbstractSet[Tuple[builtins.str*, builtins.object*]]' -_testTypedDictMappingMethods.py:11: note: Revealed type is 'typing.ValuesView[builtins.object*]' +_testTypedDictMappingMethods.py:9: note: Revealed type is 'typing.KeysView[builtins.str]' +_testTypedDictMappingMethods.py:10: note: Revealed type is 'typing.ItemsView[builtins.str, builtins.object]' +_testTypedDictMappingMethods.py:11: note: Revealed type is 'typing.ValuesView[builtins.object]' _testTypedDictMappingMethods.py:12: note: Revealed type is 'TypedDict('_testTypedDictMappingMethods.Cell', {'value': builtins.int})' _testTypedDictMappingMethods.py:13: note: Revealed type is 'builtins.int' _testTypedDictMappingMethods.py:15: error: Unexpected TypedDict key 'invalid'