aboutsummaryrefslogtreecommitdiff
path: root/stdlib/test
diff options
context:
space:
mode:
authorEduardo Julian2017-09-04 21:16:42 -0400
committerEduardo Julian2017-09-04 21:16:42 -0400
commit036f3b68983381c6fd2c380f01011ddaf0d8021f (patch)
treeff0a9b644dc5ecc3b7cfb970c90c747cb922b749 /stdlib/test
parente97796bf4fd2217d3b9eaaf0b20a8f1b5f0f6b29 (diff)
- Simplified code for JSON format.
- Moved JSON polytypism to the lux/macro/poly/* branch.
Diffstat (limited to 'stdlib/test')
-rw-r--r--stdlib/test/test/lux/data/format/json.lux11
1 files changed, 5 insertions, 6 deletions
diff --git a/stdlib/test/test/lux/data/format/json.lux b/stdlib/test/test/lux/data/format/json.lux
index 2dce7ad84..bd0e4ab67 100644
--- a/stdlib/test/test/lux/data/format/json.lux
+++ b/stdlib/test/test/lux/data/format/json.lux
@@ -12,9 +12,7 @@
[bool]
[maybe]
[number "i/" Number<Int>]
- (format ["@" json]
- (json ["@;" reader]
- ["@;" codec]))
+ (format ["@" json])
(coll [vector #+ vector]
["d" dict]
[list]))
@@ -22,7 +20,8 @@
(macro [code]
[syntax #+ syntax:]
[poly #+ derived:]
- [poly/eq])
+ [poly/eq]
+ [poly/json])
["r" math/random]
test)
)
@@ -44,7 +43,7 @@
(context: "JSON"
[sample gen-json
#let [(^open "@/") @;Eq<JSON>
- (^open "@/") @codec;Codec<Text,JSON>]]
+ (^open "@/") @;Codec<Text,JSON>]]
($_ seq
(test "Every JSON is equal to itself."
(@/= sample sample))
@@ -104,7 +103,7 @@
gen-recursive
)))
-(derived: (@codec;Codec<JSON,?> Record))
+(derived: (poly/json;Codec<JSON,?> Record))
(struct: _ (Eq Record)
(def: (= recL recR)