]> Nishi Git Mirror - gwion.git/commitdiff
:white_check_mark: Add tests
authorfennecdjay <astor.jeremie@wanadoo.fr>
Sat, 17 Aug 2019 13:20:26 +0000 (15:20 +0200)
committerfennecdjay <astor.jeremie@wanadoo.fr>
Sat, 17 Aug 2019 13:20:26 +0000 (15:20 +0200)
tests/tuple/array_tuple_array.gw [new file with mode: 0644]
tests/tuple/tuple_empty.gw [new file with mode: 0644]

diff --git a/tests/tuple/array_tuple_array.gw b/tests/tuple/array_tuple_array.gw
new file mode 100644 (file)
index 0000000..8ed2d13
--- /dev/null
@@ -0,0 +1,11 @@
+<([1,2], "Tom") @=> <~int[], string~>Tuple @tup;
+
+#!<<<tup[1]>>>;
+#!<<<tup[0][1]>>>;
+
+<~int[], string~>Tuple stack[3];
+tup @=> stack[2];
+<<< stack[2] >>>;
+<<< stack[2][1] >>>;
+<<< stack[2][0] >>>;
+<<< stack[2][0][1] >>>;
diff --git a/tests/tuple/tuple_empty.gw b/tests/tuple/tuple_empty.gw
new file mode 100644 (file)
index 0000000..9d1e488
--- /dev/null
@@ -0,0 +1,2 @@
+Tuple @tup;
+tup[1];