summary refs log tree commit diff stats
path: root/tests/stdlib/tjsonmacro.nim
diff options
context:
space:
mode:
authorTimothee Cour <timothee.cour2@gmail.com>2019-01-16 01:16:14 -0800
committerAndreas Rumpf <rumpf_a@web.de>2019-01-16 10:16:14 +0100
commitb8454327c52faa82632cc90dd8fa326efbb38565 (patch)
tree0590168b046180fb386b5d73a8166da18fde790b /tests/stdlib/tjsonmacro.nim
parent384e517f09cf63cde136123b163c5c021c992877 (diff)
downloadNim-b8454327c52faa82632cc90dd8fa326efbb38565.tar.gz
json: support tuple (#10010)
Diffstat (limited to 'tests/stdlib/tjsonmacro.nim')
-rw-r--r--tests/stdlib/tjsonmacro.nim4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/stdlib/tjsonmacro.nim b/tests/stdlib/tjsonmacro.nim
index 33332447b..2e95b4833 100644
--- a/tests/stdlib/tjsonmacro.nim
+++ b/tests/stdlib/tjsonmacro.nim
@@ -516,3 +516,7 @@ when true:
       var w = u.to(MyDistRef)
       doAssert v.name == "smith"
       doAssert MyRef(w).name == "smith"
+
+    block test_tuple:
+      doAssert $(%* (a1: 10, a2: "foo")) == """{"a1":10,"a2":"foo"}"""
+      doAssert $(%* (10, "foo")) == """[10,"foo"]"""