aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/test/aedifex/artifact
diff options
context:
space:
mode:
authorEduardo Julian2021-01-09 12:58:50 -0400
committerEduardo Julian2021-01-09 12:58:50 -0400
commit706ce9e4916b65c4df5101bd3cc1b4da3b2057af (patch)
treefe3f3f6b8d6c6bc5b23045a3113a4f93e6f9b04c /stdlib/source/test/aedifex/artifact
parent1ce30d50abaa330ab2125b110e245de6deda27c7 (diff)
Turned I64 and variant creation functions into constructors for JS.
Diffstat (limited to '')
-rw-r--r--stdlib/source/test/aedifex/artifact.lux2
-rw-r--r--stdlib/source/test/aedifex/artifact/value.lux38
2 files changed, 40 insertions, 0 deletions
diff --git a/stdlib/source/test/aedifex/artifact.lux b/stdlib/source/test/aedifex/artifact.lux
index dc2de91f7..7409a65e2 100644
--- a/stdlib/source/test/aedifex/artifact.lux
+++ b/stdlib/source/test/aedifex/artifact.lux
@@ -21,6 +21,7 @@
["." / #_
["#." type]
["#." extension]
+ ["#." value]
["#." time_stamp
["#/." date]
["#/." time]]]
@@ -45,6 +46,7 @@
/type.test
/extension.test
+ /value.test
/time_stamp.test
/time_stamp/date.test
/time_stamp/time.test
diff --git a/stdlib/source/test/aedifex/artifact/value.lux b/stdlib/source/test/aedifex/artifact/value.lux
new file mode 100644
index 000000000..10e9016b1
--- /dev/null
+++ b/stdlib/source/test/aedifex/artifact/value.lux
@@ -0,0 +1,38 @@
+(.module:
+ [lux #*
+ ["_" test (#+ Test)]
+ [abstract
+ [monad (#+ do)]
+ {[0 #spec]
+ [/
+ ["$." equivalence]]}]
+ [control
+ ["." try ("#\." functor)]
+ [parser
+ ["<.>" text]]]
+ [math
+ ["." random (#+ Random)]
+ [number
+ ["n" nat]
+ ["i" int]]]
+ [time
+ ["." instant]]]
+ {#program
+ ["." /]})
+
+(def: #export random
+ (Random /.Value)
+ ($_ random.and
+ (random.ascii/alpha 5)
+ random.instant
+ random.nat
+ ))
+
+(def: #export test
+ Test
+ (<| (_.covering /._)
+ (_.for [/.Build /.Value])
+ ($_ _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+ )))