From abdc4ec08d742642598555ba8e1854fe1445645e Mon Sep 17 00:00:00 2001 From: Damien George Date: Thu, 7 Apr 2022 23:54:24 +1000 Subject: [PATCH] qemu-arm/test-frzmpy: Add test for freezing constant tuples. Signed-off-by: Damien George --- ports/qemu-arm/test-frzmpy/frozen_const.py | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 ports/qemu-arm/test-frzmpy/frozen_const.py diff --git a/ports/qemu-arm/test-frzmpy/frozen_const.py b/ports/qemu-arm/test-frzmpy/frozen_const.py new file mode 100644 index 0000000000..19af4a3e2a --- /dev/null +++ b/ports/qemu-arm/test-frzmpy/frozen_const.py @@ -0,0 +1,11 @@ +# Test freezing constants. + +x0 = (1,) +x1 = (1, 2) +x2 = (1, 1 << 100) +x3 = (None, False, True, ...) +x4 = ("str", b"bytes") +x5 = ((),) +x6 = ((1,),) +x7 = ((1, 2),) +x8 = (1, "str", (), ("nested", 2, ((False, True), None, ...)))