Commit 964fb245 authored by Alex March's avatar Alex March Committed by Paul Sokolovsky
Browse files

tests/basics/gc1: Garbage collector threshold() coverage.

parent 8a49905a
......@@ -20,3 +20,11 @@ if hasattr(gc, 'mem_free'):
# just test they execute and return an int
assert type(gc.mem_free()) is int
assert type(gc.mem_alloc()) is int
if hasattr(gc, 'threshold'):
# uPy has this extra function
# check execution and returns
assert(gc.threshold(1) is None)
assert(gc.threshold() == 0)
assert(gc.threshold(-1) is None)
assert(gc.threshold() == -1)
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