micropython/tests/micropython
Damien George 791b65f4b2 py/modmicropython: Add micropython.const, alias for identity function.
Having a micropython.const identity function, and writing "from micropython
import const" at the start of scripts that use the const feature, allows to
write scripts which are compatible with CPython, and with uPy builds that
don't include const optimisation.

This patch adds such a function and updates the tests to do the import.
2016-09-27 13:34:21 +10:00
..
const.py py/modmicropython: Add micropython.const, alias for identity function. 2016-09-27 13:34:21 +10:00
const.py.exp py/parse: Treat constants that start with underscore as private. 2016-06-06 17:28:32 +01:00
const2.py py/modmicropython: Add micropython.const, alias for identity function. 2016-09-27 13:34:21 +10:00
const2.py.exp tests/micropython: Add tests for const names being replaced in parser. 2016-09-27 13:03:53 +10:00
const_error.py py/modmicropython: Add micropython.const, alias for identity function. 2016-09-27 13:34:21 +10:00
const_error.py.exp tests: Add tests for SyntaxError, TypeError, and other missing things. 2015-03-25 23:10:09 +00:00
decorator.py tests: Add tests for things that are not already tested. 2015-03-12 22:48:45 +00:00
decorator.py.exp tests: Add tests for things that are not already tested. 2015-03-12 22:48:45 +00:00
decorator_error.py tests: Add tests for SyntaxError, TypeError, and other missing things. 2015-03-25 23:10:09 +00:00
decorator_error.py.exp tests: Add tests for SyntaxError, TypeError, and other missing things. 2015-03-25 23:10:09 +00:00
heapalloc.py py: Fallback to stack alloca for Python-stack if heap alloc fails. 2015-06-08 22:07:27 +01:00
heapalloc.py.exp py: Fallback to stack alloca for Python-stack if heap alloc fails. 2015-06-08 22:07:27 +01:00
meminfo.py tests: Add missing tests for builtins, and many other things. 2015-04-04 22:05:30 +01:00
meminfo.py.exp tests/meminfo: Update for addition of "max free sz" output. 2016-07-01 00:39:26 +03:00
memstats.py tests: Add missing tests for builtins, and many other things. 2015-04-04 22:05:30 +01:00
memstats.py.exp tests: Add missing tests for builtins, and many other things. 2015-04-04 22:05:30 +01:00
native_closure.py tests: Add specific test for closures in native emitter. 2015-04-03 16:14:25 +01:00
native_closure.py.exp tests: Add specific test for closures in native emitter. 2015-04-03 16:14:25 +01:00
native_const.py tests: Remove obsolete test; don't use fp in micropython/ tests. 2015-02-15 01:57:39 +00:00
native_const.py.exp tests: Remove obsolete test; don't use fp in micropython/ tests. 2015-02-15 01:57:39 +00:00
native_misc.py tests: Add tests for SyntaxError, TypeError, and other missing things. 2015-03-25 23:10:09 +00:00
native_misc.py.exp tests: Add tests for SyntaxError, TypeError, and other missing things. 2015-03-25 23:10:09 +00:00
viper_addr.py py/viper: Allow casting of Python integers to viper pointers. 2016-02-09 13:29:20 +00:00
viper_addr.py.exp py/viper: Allow casting of Python integers to viper pointers. 2016-02-09 13:29:20 +00:00
viper_args.py py: Allow viper functions to take up to 4 arguments. 2015-07-23 14:11:29 +01:00
viper_args.py.exp py: Allow viper functions to take up to 4 arguments. 2015-07-23 14:11:29 +01:00
viper_binop_arith.py py: Implement native multiply operation in viper emitter. 2015-06-04 14:00:29 +00:00
viper_binop_arith.py.exp py: Implement native multiply operation in viper emitter. 2015-06-04 14:00:29 +00:00
viper_binop_comp.py tests: Add tests for viper binary operations. 2014-09-29 19:42:06 +01:00
viper_binop_comp.py.exp tests: Add tests for viper binary operations. 2014-09-29 19:42:06 +01:00
viper_binop_comp_imm.py asmarm: Fix bug with encoding small negative ints using MVN instruction. 2014-12-14 03:24:17 +02:00
viper_binop_comp_imm.py.exp asmarm: Fix bug with encoding small negative ints using MVN instruction. 2014-12-14 03:24:17 +02:00
viper_binop_multi_comp.py py: Partially fix viper multi-comparison; add test for it. 2014-10-19 19:00:51 +01:00
viper_binop_multi_comp.py.exp py: Partially fix viper multi-comparison; add test for it. 2014-10-19 19:00:51 +01:00
viper_cond.py tests: Add more tests for viper, including tests for ViperTypeError's. 2015-04-22 23:18:28 +01:00
viper_cond.py.exp tests: Add more tests for viper, including tests for ViperTypeError's. 2015-04-22 23:18:28 +01:00
viper_error.py py/emitnative: Raise ViperTypeError for unsupported unary ops. 2015-10-08 13:08:59 +01:00
viper_error.py.exp py/emitnative: Raise ViperTypeError for unsupported unary ops. 2015-10-08 13:08:59 +01:00
viper_misc.py tests: Add more tests for viper 16/32-bit load/store, and ellipsis. 2015-10-13 18:24:36 +01:00
viper_misc.py.exp tests: Add more tests for viper 16/32-bit load/store, and ellipsis. 2015-10-13 18:24:36 +01:00
viper_ptr8_load.py tests: Add more tests for viper, including tests for ViperTypeError's. 2015-04-22 23:18:28 +01:00
viper_ptr8_load.py.exp tests: Add more tests for viper, including tests for ViperTypeError's. 2015-04-22 23:18:28 +01:00
viper_ptr8_store.py tests: Add more tests for viper, including tests for ViperTypeError's. 2015-04-22 23:18:28 +01:00
viper_ptr8_store.py.exp tests: Add more tests for viper, including tests for ViperTypeError's. 2015-04-22 23:18:28 +01:00
viper_ptr16_load.py tests: Add more tests for viper 16/32-bit load/store, and ellipsis. 2015-10-13 18:24:36 +01:00
viper_ptr16_load.py.exp tests: Add more tests for viper 16/32-bit load/store, and ellipsis. 2015-10-13 18:24:36 +01:00
viper_ptr16_store.py tests: Add more tests for viper 16/32-bit load/store, and ellipsis. 2015-10-13 18:24:36 +01:00
viper_ptr16_store.py.exp tests: Add more tests for viper 16/32-bit load/store, and ellipsis. 2015-10-13 18:24:36 +01:00
viper_ptr32_load.py tests: Add more tests for viper 16/32-bit load/store, and ellipsis. 2015-10-13 18:24:36 +01:00
viper_ptr32_load.py.exp tests: Add more tests for viper 16/32-bit load/store, and ellipsis. 2015-10-13 18:24:36 +01:00
viper_ptr32_store.py tests: Add more tests for viper 16/32-bit load/store, and ellipsis. 2015-10-13 18:24:36 +01:00
viper_ptr32_store.py.exp tests: Add more tests for viper 16/32-bit load/store, and ellipsis. 2015-10-13 18:24:36 +01:00
viper_subscr.py py: Implement implicit cast to obj for viper load/store index/value. 2015-06-04 11:52:16 +01:00
viper_subscr.py.exp py: Implement implicit cast to obj for viper load/store index/value. 2015-06-04 11:52:16 +01:00