diff options
author | Damien George <damien.p.george@gmail.com> | 2014-10-05 22:27:12 +0100 |
---|---|---|
committer | Damien George <damien.p.george@gmail.com> | 2014-10-05 22:27:12 +0100 |
commit | 5a04e2cca8255c2d4a1218d6ac0b38e67306206b (patch) | |
tree | b70ec6a20f17b7282828268725eb4faf915493e6 /tests/micropython/native_misc.py | |
parent | 854c8c015303d709d3b33f5897dbeff0c10bee9d (diff) |
tests: Add check for micropython.native and then skip relevant tests.
If micropython.native decorator doesn't compile, then we skill all
native/viper tests.
This patch also re-enables the ujson_loads test on NT.
Addresses issue #861, and partially addresses issue #856.
Diffstat (limited to 'tests/micropython/native_misc.py')
-rw-r--r-- | tests/micropython/native_misc.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/micropython/native_misc.py b/tests/micropython/native_misc.py new file mode 100644 index 000000000..8f087c494 --- /dev/null +++ b/tests/micropython/native_misc.py @@ -0,0 +1,10 @@ +@micropython.native +def native_test(x): + print(1, [], x) + +native_test(2) + +# check that GC doesn't collect the native function +import gc +gc.collect() +native_test(3) |