aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorDamien George2020-01-06 23:26:00 +1100
committerDamien George2020-01-06 23:26:00 +1100
commit4d528bbaa836b3d6ec0218ca7f7c92e1bf73704c (patch)
tree2e3068b48614e8eb16eecbe524139f4ba14a40cb /tests
parent99b8c1a93731771bd7d8801a8ea939922f3d2991 (diff)
tests/cpydiff: Add CPy diff-test for using dict.keys() as a set.
See issue #5493.
Diffstat (limited to 'tests')
-rw-r--r--tests/cpydiff/types_dict_keys_set.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/cpydiff/types_dict_keys_set.py b/tests/cpydiff/types_dict_keys_set.py
new file mode 100644
index 000000000..1a9af9d38
--- /dev/null
+++ b/tests/cpydiff/types_dict_keys_set.py
@@ -0,0 +1,7 @@
+"""
+categories: Types,dict
+description: Dictionary keys view does not behave as a set.
+cause: Not implemented.
+workaround: Explicitly convert keys to a set before using set operations.
+"""
+print({1:2, 3:4}.keys() & {1})