Commit 7839b8b8 authored by Damien George's avatar Damien George
Browse files

tests/micropython/heapalloc_iter: Add tests for contains and unpack.

parent e6003f46
......@@ -25,6 +25,22 @@ fs = frozenset((1,))
g1 = (100 + x for x in range(2))
g2 = gen_func()
# test containment (both success and failure) with the heap locked
print(49 in b'123', 255 in b'123')
print(1 in t, -1 in t)
print(1 in l, -1 in l)
print(1 in d, -1 in d)
print(1 in s, -1 in s)
# test unpacking with the heap locked
unp0 = unp1 = unp2 = None # preallocate slots for globals
unp0, unp1, unp2 = t
print(unp0, unp1, unp2)
# test certain builtins with the heap locked
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment