Skip to content

Commit a160b70

Browse files
committed
tests: Add test on set/frozenset equality.
1 parent 8b3b2d0 commit a160b70

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

tests/basics/frozenset_set.py

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
try:
2+
frozenset
3+
except NameError:
4+
print("SKIP")
5+
import sys
6+
sys.exit()
7+
8+
# Examples from https://docs.python.org/3/library/stdtypes.html#set
9+
# "Instances of set are compared to instances of frozenset based on their
10+
# members. For example:"
11+
print(set('abc') == frozenset('abc'))
12+
# This doesn't work in uPy
13+
#print(set('abc') in set([frozenset('abc')]))

0 commit comments

Comments
 (0)