aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/test/aedifex
diff options
context:
space:
mode:
authorEduardo Julian2022-04-08 05:42:36 -0400
committerEduardo Julian2022-04-08 05:42:36 -0400
commit0d909187d5b9effcd08f533d50af7d29c0d6bfd8 (patch)
treec50f12c5e47e3db90c3a701b54ee9953da942210 /stdlib/source/test/aedifex
parente5e4c2aff562e5c01fefb808d1d68a40f29c9cc5 (diff)
De-sigil-ification: $
Diffstat (limited to '')
-rw-r--r--stdlib/source/test/aedifex.lux96
-rw-r--r--stdlib/source/test/aedifex/artifact.lux94
-rw-r--r--stdlib/source/test/aedifex/artifact/extension.lux72
-rw-r--r--stdlib/source/test/aedifex/artifact/snapshot.lux76
-rw-r--r--stdlib/source/test/aedifex/artifact/snapshot/build.lux58
-rw-r--r--stdlib/source/test/aedifex/artifact/snapshot/stamp.lux72
-rw-r--r--stdlib/source/test/aedifex/artifact/snapshot/time.lux62
-rw-r--r--stdlib/source/test/aedifex/artifact/snapshot/version.lux78
-rw-r--r--stdlib/source/test/aedifex/artifact/snapshot/version/value.lux52
-rw-r--r--stdlib/source/test/aedifex/artifact/time.lux92
-rw-r--r--stdlib/source/test/aedifex/artifact/time/date.lux94
-rw-r--r--stdlib/source/test/aedifex/artifact/time/time.lux20
-rw-r--r--stdlib/source/test/aedifex/artifact/type.lux68
-rw-r--r--stdlib/source/test/aedifex/artifact/versioning.lux90
-rw-r--r--stdlib/source/test/aedifex/cache.lux14
-rw-r--r--stdlib/source/test/aedifex/cli.lux56
-rw-r--r--stdlib/source/test/aedifex/command.lux54
-rw-r--r--stdlib/source/test/aedifex/command/auto.lux64
-rw-r--r--stdlib/source/test/aedifex/command/build.lux204
-rw-r--r--stdlib/source/test/aedifex/command/install.lux64
-rw-r--r--stdlib/source/test/aedifex/command/test.lux110
-rw-r--r--stdlib/source/test/aedifex/dependency.lux52
-rw-r--r--stdlib/source/test/aedifex/dependency/deployment.lux102
-rw-r--r--stdlib/source/test/aedifex/dependency/resolution.lux188
-rw-r--r--stdlib/source/test/aedifex/dependency/status.lux72
-rw-r--r--stdlib/source/test/aedifex/hash.lux152
-rw-r--r--stdlib/source/test/aedifex/local.lux10
-rw-r--r--stdlib/source/test/aedifex/metadata.lux92
-rw-r--r--stdlib/source/test/aedifex/metadata/artifact.lux116
-rw-r--r--stdlib/source/test/aedifex/metadata/snapshot.lux86
-rw-r--r--stdlib/source/test/aedifex/package.lux118
-rw-r--r--stdlib/source/test/aedifex/pom.lux54
-rw-r--r--stdlib/source/test/aedifex/profile.lux118
-rw-r--r--stdlib/source/test/aedifex/project.lux110
-rw-r--r--stdlib/source/test/aedifex/repository.lux34
-rw-r--r--stdlib/source/test/aedifex/repository/identity.lux36
-rw-r--r--stdlib/source/test/aedifex/repository/local.lux72
-rw-r--r--stdlib/source/test/aedifex/repository/origin.lux36
-rw-r--r--stdlib/source/test/aedifex/repository/remote.lux74
-rw-r--r--stdlib/source/test/aedifex/runtime.lux68
40 files changed, 1590 insertions, 1590 deletions
diff --git a/stdlib/source/test/aedifex.lux b/stdlib/source/test/aedifex.lux
index 2c30c2a37..ed891d815 100644
--- a/stdlib/source/test/aedifex.lux
+++ b/stdlib/source/test/aedifex.lux
@@ -1,58 +1,58 @@
(.using
- [library
- [lux "*"
- [program {"+" program:}]
- ["_" test {"+" Test}]
- [control
- ["[0]" io]]]]
- ["[0]" / "_"
- ["[1][0]" artifact]
- ["[1][0]" cli]
- ["[1][0]" command]
- ["[1][0]" dependency
- ["[1]/[0]" deployment]
- ["[1]/[0]" resolution]
- ["[1]/[0]" status]]
- ["[1][0]" hash]
- ["[1][0]" input]
- ["[1][0]" local]
- ["[1][0]" metadata]
- ["[1][0]" package]
- ["[1][0]" parser]
- ["[1][0]" pom]
- ["[1][0]" profile]
- ["[1][0]" project]
- ["[1][0]" repository]
- ["[1][0]" runtime]])
+ [library
+ [lux "*"
+ [program {"+" program:}]
+ ["_" test {"+" Test}]
+ [control
+ ["[0]" io]]]]
+ ["[0]" / "_"
+ ["[1][0]" artifact]
+ ["[1][0]" cli]
+ ["[1][0]" command]
+ ["[1][0]" dependency
+ ["[1]/[0]" deployment]
+ ["[1]/[0]" resolution]
+ ["[1]/[0]" status]]
+ ["[1][0]" hash]
+ ["[1][0]" input]
+ ["[1][0]" local]
+ ["[1][0]" metadata]
+ ["[1][0]" package]
+ ["[1][0]" parser]
+ ["[1][0]" pom]
+ ["[1][0]" profile]
+ ["[1][0]" project]
+ ["[1][0]" repository]
+ ["[1][0]" runtime]])
(def: dependency
Test
- ($_ _.and
- /dependency.test
- /dependency/deployment.test
- /dependency/resolution.test
- /dependency/status.test
- ))
+ (all _.and
+ /dependency.test
+ /dependency/deployment.test
+ /dependency/resolution.test
+ /dependency/status.test
+ ))
(def: test
Test
- ($_ _.and
- /artifact.test
- /cli.test
- /command.test
- ..dependency
- /hash.test
- /input.test
- /local.test
- /metadata.test
- /package.test
- /parser.test
- /pom.test
- /profile.test
- /project.test
- /repository.test
- /runtime.test
- ))
+ (all _.and
+ /artifact.test
+ /cli.test
+ /command.test
+ ..dependency
+ /hash.test
+ /input.test
+ /local.test
+ /metadata.test
+ /package.test
+ /parser.test
+ /pom.test
+ /profile.test
+ /project.test
+ /repository.test
+ /runtime.test
+ ))
(program: args
(<| io.io
diff --git a/stdlib/source/test/aedifex/artifact.lux b/stdlib/source/test/aedifex/artifact.lux
index 11ff833da..1a0c7cb29 100644
--- a/stdlib/source/test/aedifex/artifact.lux
+++ b/stdlib/source/test/aedifex/artifact.lux
@@ -1,38 +1,38 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [hash {"+" Hash}]
- [\\specification
- ["$[0]" equivalence]
- ["$[0]" order]
- ["$[0]" hash]]]
- [data
- ["[0]" text ("[1]#[0]" equivalence)]]
- [math
- ["[0]" random {"+" Random}]]
- [world
- ["[0]" file]
- [net
- ["[0]" uri]]]]]
- ["[0]" / "_"
- ["[1][0]" extension]
- ["[1][0]" snapshot]
- ["[1][0]" time]
- ["[1][0]" type]
- ["[1][0]" versioning]]
- [\\program
- ["[0]" /]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [hash {"+" Hash}]
+ [\\specification
+ ["$[0]" equivalence]
+ ["$[0]" order]
+ ["$[0]" hash]]]
+ [data
+ ["[0]" text ("[1]#[0]" equivalence)]]
+ [math
+ ["[0]" random {"+" Random}]]
+ [world
+ ["[0]" file]
+ [net
+ ["[0]" uri]]]]]
+ ["[0]" / "_"
+ ["[1][0]" extension]
+ ["[1][0]" snapshot]
+ ["[1][0]" time]
+ ["[1][0]" type]
+ ["[1][0]" versioning]]
+ [\\program
+ ["[0]" /]])
(def: .public random
(Random /.Artifact)
(let [size 4]
- ($_ random.and
- (random.ascii/lower size)
- (random.ascii/lower size)
- (random.ascii/lower size))))
+ (all random.and
+ (random.ascii/lower size)
+ (random.ascii/lower size)
+ (random.ascii/lower size))))
(def: .public test
Test
@@ -41,21 +41,21 @@
[sample ..random])
(_.for [/.Group /.Name /.Version
/.Artifact]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
- (_.for [/.order]
- ($order.spec /.order ..random))
- (_.for [/.hash]
- ($hash.spec /.hash ..random))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+ (_.for [/.order]
+ ($order.spec /.order ..random))
+ (_.for [/.hash]
+ ($hash.spec /.hash ..random))
- (_.cover [/.format /.identity]
- (and (text.ends_with? (/.identity sample) (/.format sample))
- (not (text#= (/.identity sample) (/.format sample)))))
-
- /extension.test
- /snapshot.test
- /time.test
- /type.test
- /versioning.test
- ))))
+ (_.cover [/.format /.identity]
+ (and (text.ends_with? (/.identity sample) (/.format sample))
+ (not (text#= (/.identity sample) (/.format sample)))))
+
+ /extension.test
+ /snapshot.test
+ /time.test
+ /type.test
+ /versioning.test
+ ))))
diff --git a/stdlib/source/test/aedifex/artifact/extension.lux b/stdlib/source/test/aedifex/artifact/extension.lux
index d1f1c4dea..b71b0c001 100644
--- a/stdlib/source/test/aedifex/artifact/extension.lux
+++ b/stdlib/source/test/aedifex/artifact/extension.lux
@@ -1,43 +1,43 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]]
- [data
- ["[0]" text ("[1]#[0]" equivalence)]
- [collection
- ["[0]" set]
- ["[0]" list]]]
- [math
- ["[0]" random {"+" Random}]
- [number
- ["n" nat]]]]]
- [\\program
- ["[0]" /
- ["/[1]" // "_"
- ["[1]" type]]]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]]
+ [data
+ ["[0]" text ("[1]#[0]" equivalence)]
+ [collection
+ ["[0]" set]
+ ["[0]" list]]]
+ [math
+ ["[0]" random {"+" Random}]
+ [number
+ ["n" nat]]]]]
+ [\\program
+ ["[0]" /
+ ["/[1]" // "_"
+ ["[1]" type]]]])
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Extension]
- ($_ _.and
- (_.cover [/.lux_library /.jvm_library /.pom
- /.sha-1 /.md5]
- (let [options (list /.lux_library /.jvm_library /.pom /.sha-1 /.md5)
- uniques (set.of_list text.hash options)]
- (n.= (list.size options)
- (set.size uniques))))
- (_.cover [/.extension /.type]
- (`` (and (~~ (template [<type> <extension>]
- [(and (text#= <extension>
- (/.extension <type>))
- (text#= <type>
- (/.type (/.extension <type>))))]
+ (all _.and
+ (_.cover [/.lux_library /.jvm_library /.pom
+ /.sha-1 /.md5]
+ (let [options (list /.lux_library /.jvm_library /.pom /.sha-1 /.md5)
+ uniques (set.of_list text.hash options)]
+ (n.= (list.size options)
+ (set.size uniques))))
+ (_.cover [/.extension /.type]
+ (`` (and (~~ (template [<type> <extension>]
+ [(and (text#= <extension>
+ (/.extension <type>))
+ (text#= <type>
+ (/.type (/.extension <type>))))]
- [//.lux_library /.lux_library]
- [//.jvm_library /.jvm_library]
- [//.pom /.pom]
- )))))
- ))))
+ [//.lux_library /.lux_library]
+ [//.jvm_library /.jvm_library]
+ [//.pom /.pom]
+ )))))
+ ))))
diff --git a/stdlib/source/test/aedifex/artifact/snapshot.lux b/stdlib/source/test/aedifex/artifact/snapshot.lux
index b2c6417b1..cea873a6e 100644
--- a/stdlib/source/test/aedifex/artifact/snapshot.lux
+++ b/stdlib/source/test/aedifex/artifact/snapshot.lux
@@ -1,24 +1,24 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]]]
- [control
- ["[0]" try ("[1]#[0]" functor)]
- [parser
- ["<[0]>" xml]]]
- [math
- ["[0]" random {"+" Random} ("[1]#[0]" monad)]]]]
- ["$[0]" / "_"
- ["[1][0]" build]
- ["[1][0]" stamp]
- ["[1][0]" time]
- ["[1][0]" version]]
- [\\program
- ["[0]" /]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]]]
+ [control
+ ["[0]" try ("[1]#[0]" functor)]
+ [parser
+ ["<[0]>" xml]]]
+ [math
+ ["[0]" random {"+" Random} ("[1]#[0]" monad)]]]]
+ ["$[0]" / "_"
+ ["[1][0]" build]
+ ["[1][0]" stamp]
+ ["[1][0]" time]
+ ["[1][0]" version]]
+ [\\program
+ ["[0]" /]])
(def: .public random
(Random /.Snapshot)
@@ -29,22 +29,22 @@
Test
(<| (_.covering /._)
(_.for [/.Snapshot]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
-
- (do random.monad
- [expected ..random]
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- list
- (<xml>.result /.parser)
- (try#each (# /.equivalence = expected))
- (try.else false))))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+
+ (do random.monad
+ [expected ..random]
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ list
+ (<xml>.result /.parser)
+ (try#each (# /.equivalence = expected))
+ (try.else false))))
- $/build.test
- $/stamp.test
- $/time.test
- $/version.test
- ))))
+ $/build.test
+ $/stamp.test
+ $/time.test
+ $/version.test
+ ))))
diff --git a/stdlib/source/test/aedifex/artifact/snapshot/build.lux b/stdlib/source/test/aedifex/artifact/snapshot/build.lux
index 0f3ca9799..b03fe7f10 100644
--- a/stdlib/source/test/aedifex/artifact/snapshot/build.lux
+++ b/stdlib/source/test/aedifex/artifact/snapshot/build.lux
@@ -1,19 +1,19 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]]]
- [control
- ["[0]" try ("[1]#[0]" functor)]
- [parser
- ["<[0]>" xml]]]
- [math
- ["[0]" random {"+" Random}]]]]
- [\\program
- ["[0]" /]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]]]
+ [control
+ ["[0]" try ("[1]#[0]" functor)]
+ [parser
+ ["<[0]>" xml]]]
+ [math
+ ["[0]" random {"+" Random}]]]]
+ [\\program
+ ["[0]" /]])
(def: .public random
(Random /.Build)
@@ -23,17 +23,17 @@
Test
(<| (_.covering /._)
(_.for [/.Build]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
-
- (do random.monad
- [expected ..random]
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- list
- (<xml>.result /.parser)
- (try#each (# /.equivalence = expected))
- (try.else false))))
- ))))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+
+ (do random.monad
+ [expected ..random]
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ list
+ (<xml>.result /.parser)
+ (try#each (# /.equivalence = expected))
+ (try.else false))))
+ ))))
diff --git a/stdlib/source/test/aedifex/artifact/snapshot/stamp.lux b/stdlib/source/test/aedifex/artifact/snapshot/stamp.lux
index 3fa32fe46..181e39523 100644
--- a/stdlib/source/test/aedifex/artifact/snapshot/stamp.lux
+++ b/stdlib/source/test/aedifex/artifact/snapshot/stamp.lux
@@ -1,46 +1,46 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]]]
- [control
- ["[0]" try ("[1]#[0]" functor)]
- [parser
- ["<[0]>" xml]]]
- [math
- ["[0]" random {"+" Random}]]
- [time
- ["[0]" instant]]]]
- [\\program
- ["[0]" /]]
- ["$[0]" // "_"
- ["[1][0]" time]
- ["[1][0]" build]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]]]
+ [control
+ ["[0]" try ("[1]#[0]" functor)]
+ [parser
+ ["<[0]>" xml]]]
+ [math
+ ["[0]" random {"+" Random}]]
+ [time
+ ["[0]" instant]]]]
+ [\\program
+ ["[0]" /]]
+ ["$[0]" // "_"
+ ["[1][0]" time]
+ ["[1][0]" build]])
(def: .public random
(Random /.Stamp)
- ($_ random.and
- $//time.random
- $//build.random
- ))
+ (all random.and
+ $//time.random
+ $//build.random
+ ))
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Stamp])
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
- (do random.monad
- [expected ..random]
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- (<xml>.result /.parser)
- (try#each (# /.equivalence = expected))
- (try.else false))))
- )))
+ (do random.monad
+ [expected ..random]
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ (<xml>.result /.parser)
+ (try#each (# /.equivalence = expected))
+ (try.else false))))
+ )))
diff --git a/stdlib/source/test/aedifex/artifact/snapshot/time.lux b/stdlib/source/test/aedifex/artifact/snapshot/time.lux
index b48a8265f..4e8a63fe5 100644
--- a/stdlib/source/test/aedifex/artifact/snapshot/time.lux
+++ b/stdlib/source/test/aedifex/artifact/snapshot/time.lux
@@ -1,21 +1,21 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]]]
- [control
- ["[0]" try ("[1]#[0]" functor)]
- [parser
- ["<[0]>" text]]]
- [math
- ["[0]" random {"+" Random}]]]]
- [\\program
- ["[0]" /]]
- ["$[0]" /// "_"
- ["[1][0]" time]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]]]
+ [control
+ ["[0]" try ("[1]#[0]" functor)]
+ [parser
+ ["<[0]>" text]]]
+ [math
+ ["[0]" random {"+" Random}]]]]
+ [\\program
+ ["[0]" /]]
+ ["$[0]" /// "_"
+ ["[1][0]" time]])
(def: .public random
(Random /.Time)
@@ -25,18 +25,18 @@
Test
(<| (_.covering /._)
(_.for [/.Time])
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
- (do random.monad
- [expected ..random]
- ($_ _.and
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- (<text>.result /.parser)
- (try#each (# /.equivalence = expected))
- (try.else false)))
- ))
- )))
+ (do random.monad
+ [expected ..random]
+ (all _.and
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ (<text>.result /.parser)
+ (try#each (# /.equivalence = expected))
+ (try.else false)))
+ ))
+ )))
diff --git a/stdlib/source/test/aedifex/artifact/snapshot/version.lux b/stdlib/source/test/aedifex/artifact/snapshot/version.lux
index 1f83c119d..1d32ff734 100644
--- a/stdlib/source/test/aedifex/artifact/snapshot/version.lux
+++ b/stdlib/source/test/aedifex/artifact/snapshot/version.lux
@@ -1,50 +1,50 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]]]
- [control
- ["[0]" try ("[1]#[0]" functor)]
- [parser
- ["<[0]>" xml]]]
- [math
- ["[0]" random {"+" Random}]]]]
- [\\program
- ["[0]" /]]
- ["[0]" / "_"
- ["[1][0]" value]]
- ["$[0]" /// "_"
- ["[1][0]" type]
- ["[1][0]" time]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]]]
+ [control
+ ["[0]" try ("[1]#[0]" functor)]
+ [parser
+ ["<[0]>" xml]]]
+ [math
+ ["[0]" random {"+" Random}]]]]
+ [\\program
+ ["[0]" /]]
+ ["[0]" / "_"
+ ["[1][0]" value]]
+ ["$[0]" /// "_"
+ ["[1][0]" type]
+ ["[1][0]" time]])
(def: .public random
(Random /.Version)
- ($_ random.and
- $///type.random
- (random.ascii/alpha 1)
- $///time.random
- ))
+ (all random.and
+ $///type.random
+ (random.ascii/alpha 1)
+ $///time.random
+ ))
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Version])
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
- (do random.monad
- [expected ..random]
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- list
- (<xml>.result /.parser)
- (try#each (# /.equivalence = expected))
- (try.else false))))
+ (do random.monad
+ [expected ..random]
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ list
+ (<xml>.result /.parser)
+ (try#each (# /.equivalence = expected))
+ (try.else false))))
- /value.test
- )))
+ /value.test
+ )))
diff --git a/stdlib/source/test/aedifex/artifact/snapshot/version/value.lux b/stdlib/source/test/aedifex/artifact/snapshot/version/value.lux
index fba89a430..7967e935f 100644
--- a/stdlib/source/test/aedifex/artifact/snapshot/version/value.lux
+++ b/stdlib/source/test/aedifex/artifact/snapshot/version/value.lux
@@ -30,37 +30,37 @@
(def: .public random
(Random /.Value)
- ($_ random.and
- (random.ascii/alpha 5)
- (random.or (random#in [])
- $///stamp.random)
- ))
+ (all random.and
+ (random.ascii/alpha 5)
+ (random.or (random#in [])
+ $///stamp.random)
+ ))
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Value])
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
- (do random.monad
- [sample random
- stamp $///stamp.random]
- (let [version (the /.#version sample)
+ (do random.monad
+ [sample random
+ stamp $///stamp.random]
+ (let [version (the /.#version sample)
- local!
- (text#= version
- (/.format (has /.#snapshot {///.#Local} sample)))
+ local!
+ (text#= version
+ (/.format (has /.#snapshot {///.#Local} sample)))
- remote_format (/.format [/.#version (format version /.snapshot)
- /.#snapshot {///.#Remote stamp}])
- remote!
- (and (text.starts_with? (format version (///time.format (the ///stamp.#time stamp)))
- remote_format)
- (text.ends_with? (%.nat (the ///stamp.#build stamp))
- remote_format))]
- (_.cover [/.snapshot /.format]
- (and local!
- remote!))))
- )))
+ remote_format (/.format [/.#version (format version /.snapshot)
+ /.#snapshot {///.#Remote stamp}])
+ remote!
+ (and (text.starts_with? (format version (///time.format (the ///stamp.#time stamp)))
+ remote_format)
+ (text.ends_with? (%.nat (the ///stamp.#build stamp))
+ remote_format))]
+ (_.cover [/.snapshot /.format]
+ (and local!
+ remote!))))
+ )))
diff --git a/stdlib/source/test/aedifex/artifact/time.lux b/stdlib/source/test/aedifex/artifact/time.lux
index 671fbfdfa..d8f67e45a 100644
--- a/stdlib/source/test/aedifex/artifact/time.lux
+++ b/stdlib/source/test/aedifex/artifact/time.lux
@@ -1,26 +1,26 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]]]
- [control
- ["[0]" try ("[1]#[0]" functor)]
- [parser
- ["<[0]>" text]]]
- [time
- ["[0]" instant ("[1]#[0]" equivalence)]]
- [math
- ["[0]" random {"+" Random}]
- [number
- ["i" int]]]]]
- [\\program
- ["[0]" /]]
- ["[0]" / "_"
- ["[1][0]" date]
- ["[1][0]" time]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]]]
+ [control
+ ["[0]" try ("[1]#[0]" functor)]
+ [parser
+ ["<[0]>" text]]]
+ [time
+ ["[0]" instant ("[1]#[0]" equivalence)]]
+ [math
+ ["[0]" random {"+" Random}]
+ [number
+ ["i" int]]]]]
+ [\\program
+ ["[0]" /]]
+ ["[0]" / "_"
+ ["[1][0]" date]
+ ["[1][0]" time]])
(def: .public random
(Random /.Time)
@@ -33,29 +33,29 @@
Test
(<| (_.covering /._)
(_.for [/.Time])
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
- (do random.monad
- [expected ..random]
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- (<text>.result /.parser)
- (try#each (# /.equivalence = expected))
- (try.else false))))
- (do random.monad
- [expected ..random]
- (_.cover [/.instant /.of_instant]
- (|> expected
- /.instant
- /.of_instant
- (try#each (# /.equivalence = expected))
- (try.else false))))
- (_.cover [/.epoch]
- (instant#= instant.epoch (/.instant /.epoch)))
+ (do random.monad
+ [expected ..random]
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ (<text>.result /.parser)
+ (try#each (# /.equivalence = expected))
+ (try.else false))))
+ (do random.monad
+ [expected ..random]
+ (_.cover [/.instant /.of_instant]
+ (|> expected
+ /.instant
+ /.of_instant
+ (try#each (# /.equivalence = expected))
+ (try.else false))))
+ (_.cover [/.epoch]
+ (instant#= instant.epoch (/.instant /.epoch)))
- /date.test
- /time.test
- )))
+ /date.test
+ /time.test
+ )))
diff --git a/stdlib/source/test/aedifex/artifact/time/date.lux b/stdlib/source/test/aedifex/artifact/time/date.lux
index dfca44e0d..9f5169d78 100644
--- a/stdlib/source/test/aedifex/artifact/time/date.lux
+++ b/stdlib/source/test/aedifex/artifact/time/date.lux
@@ -1,26 +1,26 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]]]
- [control
- ["[0]" try ("[1]#[0]" functor)]
- ["[0]" exception]
- [parser
- ["<[0]>" text]]]
- [math
- ["[0]" random {"+" Random}]
- [number
- ["n" nat]
- ["i" int]]]
- [time
- ["[0]" date ("[1]#[0]" equivalence)]
- ["[0]" year]]]]
- [\\program
- ["[0]" /]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]]]
+ [control
+ ["[0]" try ("[1]#[0]" functor)]
+ ["[0]" exception]
+ [parser
+ ["<[0]>" text]]]
+ [math
+ ["[0]" random {"+" Random}]
+ [number
+ ["n" nat]
+ ["i" int]]]
+ [time
+ ["[0]" date ("[1]#[0]" equivalence)]
+ ["[0]" year]]]]
+ [\\program
+ ["[0]" /]])
(def: .public random
(Random /.Date)
@@ -41,29 +41,29 @@
(do random.monad
[expected ..random
candidate random.date]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- (<text>.result /.parser)
- (try#each (# /.equivalence = expected))
- (try.else false)))
- (_.cover [/.value /.date]
- (|> expected
- /.value
- /.date
- (try#each (# /.equivalence = expected))
- (try.else false)))
- (_.cover [/.year_is_out_of_range]
- (case (/.date candidate)
- {try.#Success date}
- (same? candidate (/.value date))
-
- {try.#Failure error}
- (exception.match? /.year_is_out_of_range error)))
- (_.cover [/.epoch]
- (date#= date.epoch (/.value /.epoch)))
- ))))
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ (<text>.result /.parser)
+ (try#each (# /.equivalence = expected))
+ (try.else false)))
+ (_.cover [/.value /.date]
+ (|> expected
+ /.value
+ /.date
+ (try#each (# /.equivalence = expected))
+ (try.else false)))
+ (_.cover [/.year_is_out_of_range]
+ (case (/.date candidate)
+ {try.#Success date}
+ (same? candidate (/.value date))
+
+ {try.#Failure error}
+ (exception.match? /.year_is_out_of_range error)))
+ (_.cover [/.epoch]
+ (date#= date.epoch (/.value /.epoch)))
+ ))))
diff --git a/stdlib/source/test/aedifex/artifact/time/time.lux b/stdlib/source/test/aedifex/artifact/time/time.lux
index 64155f029..da0589d93 100644
--- a/stdlib/source/test/aedifex/artifact/time/time.lux
+++ b/stdlib/source/test/aedifex/artifact/time/time.lux
@@ -28,13 +28,13 @@
Test
(<| (_.covering /._)
(_.for [/.Time])
- ($_ _.and
- (do random.monad
- [expected ..random]
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- (<text>.result /.parser)
- (try#each (# time.equivalence = expected))
- (try.else false))))
- )))
+ (all _.and
+ (do random.monad
+ [expected ..random]
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ (<text>.result /.parser)
+ (try#each (# time.equivalence = expected))
+ (try.else false))))
+ )))
diff --git a/stdlib/source/test/aedifex/artifact/type.lux b/stdlib/source/test/aedifex/artifact/type.lux
index 41f3510e7..a5592e3ef 100644
--- a/stdlib/source/test/aedifex/artifact/type.lux
+++ b/stdlib/source/test/aedifex/artifact/type.lux
@@ -1,43 +1,43 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]]
- [data
- ["[0]" text]
- [collection
- ["[0]" set]
- ["[0]" list]]]
- [math
- ["[0]" random {"+" Random} ("[1]#[0]" monad)]
- [number
- ["n" nat]]]]]
- [\\program
- ["[0]" /]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]]
+ [data
+ ["[0]" text]
+ [collection
+ ["[0]" set]
+ ["[0]" list]]]
+ [math
+ ["[0]" random {"+" Random} ("[1]#[0]" monad)]
+ [number
+ ["n" nat]]]]]
+ [\\program
+ ["[0]" /]])
(def: .public random
(Random /.Type)
- ($_ random.either
- ($_ random.either
- (random#in /.lux_library)
- (random#in /.jvm_library))
- ($_ random.either
- (random#in /.pom)
- (random#in /.md5)
- (random#in /.sha-1))
- ))
+ (all random.either
+ (all random.either
+ (random#in /.lux_library)
+ (random#in /.jvm_library))
+ (all random.either
+ (random#in /.pom)
+ (random#in /.md5)
+ (random#in /.sha-1))
+ ))
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Type]
- ($_ _.and
- (_.cover [/.lux_library /.jvm_library /.js_library
- /.pom /.md5 /.sha-1]
- (let [options (list /.lux_library /.jvm_library /.js_library
- /.pom /.md5 /.sha-1)
- uniques (set.of_list text.hash options)]
- (n.= (list.size options)
- (set.size uniques))))
- ))))
+ (all _.and
+ (_.cover [/.lux_library /.jvm_library /.js_library
+ /.pom /.md5 /.sha-1]
+ (let [options (list /.lux_library /.jvm_library /.js_library
+ /.pom /.md5 /.sha-1)
+ uniques (set.of_list text.hash options)]
+ (n.= (list.size options)
+ (set.size uniques))))
+ ))))
diff --git a/stdlib/source/test/aedifex/artifact/versioning.lux b/stdlib/source/test/aedifex/artifact/versioning.lux
index 5a14e9638..bc029a46a 100644
--- a/stdlib/source/test/aedifex/artifact/versioning.lux
+++ b/stdlib/source/test/aedifex/artifact/versioning.lux
@@ -1,54 +1,54 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]]]
- [control
- ["[0]" try ("[1]#[0]" functor)]
- [parser
- ["<[0]>" xml]]]
- [math
- ["[0]" random {"+" Random}]]]]
- [\\program
- ["[0]" /]]
- ["$[0]" // "_"
- ["[1][0]" time]
- ["[1][0]" snapshot
- ["[1]/[0]" version]]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]]]
+ [control
+ ["[0]" try ("[1]#[0]" functor)]
+ [parser
+ ["<[0]>" xml]]]
+ [math
+ ["[0]" random {"+" Random}]]]]
+ [\\program
+ ["[0]" /]]
+ ["$[0]" // "_"
+ ["[1][0]" time]
+ ["[1][0]" snapshot
+ ["[1]/[0]" version]]])
(def: .public random
(Random /.Versioning)
- ($_ random.and
- $//snapshot.random
- $//time.random
- (random.list 5 $//snapshot/version.random)
- ))
+ (all random.and
+ $//snapshot.random
+ $//time.random
+ (random.list 5 $//snapshot/version.random)
+ ))
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Versioning])
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
-
- (do random.monad
- [expected ..random]
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- list
- (<xml>.result /.parser)
- (try#each (# /.equivalence = expected))
- (try.else false))))
- (_.cover [/.init]
- (|> /.init
- /.format
- list
- (<xml>.result /.parser)
- (try#each (# /.equivalence = /.init))
- (try.else false)))
- )))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+
+ (do random.monad
+ [expected ..random]
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ list
+ (<xml>.result /.parser)
+ (try#each (# /.equivalence = expected))
+ (try.else false))))
+ (_.cover [/.init]
+ (|> /.init
+ /.format
+ list
+ (<xml>.result /.parser)
+ (try#each (# /.equivalence = /.init))
+ (try.else false)))
+ )))
diff --git a/stdlib/source/test/aedifex/cache.lux b/stdlib/source/test/aedifex/cache.lux
index 06b33d138..ca247f3f0 100644
--- a/stdlib/source/test/aedifex/cache.lux
+++ b/stdlib/source/test/aedifex/cache.lux
@@ -47,9 +47,9 @@
(def: type
(Random Type)
- ($_ random.either
- (random#in //artifact/type.lux_library)
- (random#in //artifact/type.jvm_library)))
+ (all random.either
+ (random#in //artifact/type.lux_library)
+ (random#in //artifact/type.jvm_library)))
(def: profile
(Random [Artifact Profile XML])
@@ -145,7 +145,7 @@
(def: .public test
Test
(<| (_.covering /._)
- ($_ _.and
- ..singular
- ..plural
- )))
+ (all _.and
+ ..singular
+ ..plural
+ )))
diff --git a/stdlib/source/test/aedifex/cli.lux b/stdlib/source/test/aedifex/cli.lux
index 3f3f79b1c..4d577e737 100644
--- a/stdlib/source/test/aedifex/cli.lux
+++ b/stdlib/source/test/aedifex/cli.lux
@@ -29,26 +29,26 @@
(def: command
(Random /.Command)
- ($_ random.or
- ... #Version
- (random#in [])
- ... #Clean
- (random#in [])
- ... #POM
- (random#in [])
- ... #Dependencies
- (random#in [])
- ... #Install
- (random#in [])
- ... #Deploy
- ($_ random.and
- (random.ascii/alpha 1)
- (random.ascii/alpha 1)
- (random.ascii/alpha 1))
- ... #Compilation
- ..compilation
- ... #Auto
- ..compilation))
+ (all random.or
+ ... #Version
+ (random#in [])
+ ... #Clean
+ (random#in [])
+ ... #POM
+ (random#in [])
+ ... #Dependencies
+ (random#in [])
+ ... #Install
+ (random#in [])
+ ... #Deploy
+ (all random.and
+ (random.ascii/alpha 1)
+ (random.ascii/alpha 1)
+ (random.ascii/alpha 1))
+ ... #Compilation
+ ..compilation
+ ... #Auto
+ ..compilation))
(def: (compilation_format value)
(-> /.Compilation (List Text))
@@ -106,12 +106,12 @@
Test
(<| (_.covering /._)
(_.for [/.Compilation /.Command]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..command))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..command))
- (_.for [/.command]
- ($_ _.and
- ..without_profile
- ..with_profile
- ))))))
+ (_.for [/.command]
+ (all _.and
+ ..without_profile
+ ..with_profile
+ ))))))
diff --git a/stdlib/source/test/aedifex/command.lux b/stdlib/source/test/aedifex/command.lux
index a6b1324bb..496e1cd78 100644
--- a/stdlib/source/test/aedifex/command.lux
+++ b/stdlib/source/test/aedifex/command.lux
@@ -1,38 +1,38 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]]]
- ["[0]" / "_"
- ["[1][0]" version]
- ["[1][0]" pom]
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]]]
+ ["[0]" / "_"
+ ["[1][0]" version]
+ ["[1][0]" pom]
- ["[1][0]" clean]
- ["[1][0]" install]
+ ["[1][0]" clean]
+ ["[1][0]" install]
- ["[1][0]" deps]
- ["[1][0]" deploy]
+ ["[1][0]" deps]
+ ["[1][0]" deploy]
- ["[1][0]" build]
- ["[1][0]" test]
- ["[1][0]" auto]]
- [\\program
- ["[0]" /]])
+ ["[1][0]" build]
+ ["[1][0]" test]
+ ["[1][0]" auto]]
+ [\\program
+ ["[0]" /]])
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Command])
- ($_ _.and
- /version.test
- /pom.test
-
- /clean.test
- /install.test
+ (all _.and
+ /version.test
+ /pom.test
+
+ /clean.test
+ /install.test
- /deps.test
- /deploy.test
+ /deps.test
+ /deploy.test
- /build.test
- /test.test
- /auto.test
- )))
+ /build.test
+ /test.test
+ /auto.test
+ )))
diff --git a/stdlib/source/test/aedifex/command/auto.lux b/stdlib/source/test/aedifex/command/auto.lux
index e8d5ca1ac..1cad922f7 100644
--- a/stdlib/source/test/aedifex/command/auto.lux
+++ b/stdlib/source/test/aedifex/command/auto.lux
@@ -90,36 +90,36 @@
expected_runs (# ! each (|>> (n.% 10) (n.max 2)) random.nat)
dummy_path (# ! each (|>> (format source /)) (random.ascii/alpha 5))
[compiler resolution] $build.resolution]
- ($_ _.and
- (_.cover [/.delay]
- (n.> 0 /.delay))
- (in (do async.monad
- [verdict (do ///action.monad
- [_ (# fs make_directory source)
- _ (# fs write dummy_path (binary.empty 0))
- .let [[@runs command] (..command expected_runs end_signal fs dummy_path)]
- _ (# watcher poll [])]
- (do [! async.monad]
- [no_dangling_process! (|> profile
- (has ///.#lux compiler)
- ((/.do! 1 watcher command)
- ($version.echo "")
- (program.async (program.mock environment.empty home working_directory))
- fs
- (shell.async ($build.good_shell []))
- resolution)
- (# ! each (|>> (pipe.case
- {try.#Failure error}
- (same? end_signal error)
+ (all _.and
+ (_.cover [/.delay]
+ (n.> 0 /.delay))
+ (in (do async.monad
+ [verdict (do ///action.monad
+ [_ (# fs make_directory source)
+ _ (# fs write dummy_path (binary.empty 0))
+ .let [[@runs command] (..command expected_runs end_signal fs dummy_path)]
+ _ (# watcher poll [])]
+ (do [! async.monad]
+ [no_dangling_process! (|> profile
+ (has ///.#lux compiler)
+ ((/.do! 1 watcher command)
+ ($version.echo "")
+ (program.async (program.mock environment.empty home working_directory))
+ fs
+ (shell.async ($build.good_shell []))
+ resolution)
+ (# ! each (|>> (pipe.case
+ {try.#Failure error}
+ (same? end_signal error)
- {try.#Success _}
- false))))
- correct_number_of_runs! (|> @runs
- atom.read!
- async.future
- (# ! each (n.= expected_runs)))]
- (in {try.#Success (and correct_number_of_runs!
- no_dangling_process!)})))]
- (_.cover' [/.do!]
- (try.else false verdict))))
- ))))
+ {try.#Success _}
+ false))))
+ correct_number_of_runs! (|> @runs
+ atom.read!
+ async.future
+ (# ! each (n.= expected_runs)))]
+ (in {try.#Success (and correct_number_of_runs!
+ no_dangling_process!)})))]
+ (_.cover' [/.do!]
+ (try.else false verdict))))
+ ))))
diff --git a/stdlib/source/test/aedifex/command/build.lux b/stdlib/source/test/aedifex/command/build.lux
index a7cd30b1c..86dc41f93 100644
--- a/stdlib/source/test/aedifex/command/build.lux
+++ b/stdlib/source/test/aedifex/command/build.lux
@@ -113,19 +113,19 @@
///artifact.#name /.js_lux_name
///artifact.#version lux_version]
///dependency.#type ///artifact/type.js_library]]]
- (`` ($_ random.either
- (in js_compiler)
- (~~ (template [<compiler>]
- [(in [///dependency.#artifact [///artifact.#group /.lux_group
- ///artifact.#name <compiler>
- ///artifact.#version lux_version]
- ///dependency.#type ///artifact/type.lux_library])]
+ (`` (all random.either
+ (in js_compiler)
+ (~~ (template [<compiler>]
+ [(in [///dependency.#artifact [///artifact.#group /.lux_group
+ ///artifact.#name <compiler>
+ ///artifact.#version lux_version]
+ ///dependency.#type ///artifact/type.lux_library])]
- [/.jvm_lux_name]
- [/.python_lux_name]
- [/.lua_lux_name]
- [/.ruby_lux_name]
- ))))))
+ [/.jvm_lux_name]
+ [/.python_lux_name]
+ [/.lua_lux_name]
+ [/.ruby_lux_name]
+ ))))))
(def: .public resolution
(Random [Dependency Resolution])
@@ -158,96 +158,96 @@
profile (|> empty_profile
with_program
with_target)]]
- ($_ _.and
- (in (do async.monad
- [outcome (/.do! (@version.echo "") (program.async (program.mock environment.empty home working_directory)) fs shell ///dependency/resolution.empty
- (with_target empty_profile))]
- (_.cover' [/.no_specified_program]
- (case outcome
- {try.#Success _}
- false
+ (all _.and
+ (in (do async.monad
+ [outcome (/.do! (@version.echo "") (program.async (program.mock environment.empty home working_directory)) fs shell ///dependency/resolution.empty
+ (with_target empty_profile))]
+ (_.cover' [/.no_specified_program]
+ (case outcome
+ {try.#Success _}
+ false
- {try.#Failure error}
- (exception.match? /.no_specified_program error)))))
- (in (do async.monad
- [outcome (/.do! (@version.echo "") (program.async (program.mock environment.empty home working_directory)) fs shell ///dependency/resolution.empty profile)]
- (_.cover' [/.Lux /.no_available_lux]
- (case outcome
- {try.#Success _}
- false
+ {try.#Failure error}
+ (exception.match? /.no_specified_program error)))))
+ (in (do async.monad
+ [outcome (/.do! (@version.echo "") (program.async (program.mock environment.empty home working_directory)) fs shell ///dependency/resolution.empty profile)]
+ (_.cover' [/.Lux /.no_available_lux]
+ (case outcome
+ {try.#Success _}
+ false
- {try.#Failure error}
- (exception.match? /.no_available_lux error)))))
- (do !
- [.let [console (@version.echo "")]
- [compiler resolution] ..resolution]
- (in (do async.monad
- [verdict (do ///action.monad
- [_ (/.do! console (program.async (program.mock environment.empty home working_directory))
- fs shell resolution
- (has ///.#lux compiler profile))
- start (# console read_line [])
- end (# console read_line [])]
- (in (and (text#= /.start start)
- (text#= /.success end))))]
- (_.cover' [/.do!
- /.lux_group
- /.jvm_lux_name
- /.js_lux_name
- /.python_lux_name
- /.lua_lux_name
- /.ruby_lux_name
- /.start
- /.success]
- (try.else false verdict)))))
- (do !
- [.let [console (@version.echo "")]
- [compiler resolution] ..resolution]
- (in (do async.monad
- [verdict (do ///action.monad
- [_ (/.do! console (program.async (program.mock environment.empty home working_directory))
- fs (shell.async (..bad_shell [])) resolution
- (has ///.#lux compiler profile))
- start (# console read_line [])
- end (# console read_line [])]
- (in (and (text#= /.start start)
- (text#= /.failure end))))]
- (_.cover' [/.failure]
- (try.else false verdict)))))
- (do !
- [expected/0 (random.ascii/alpha 5)
- expected/1 (random.ascii/alpha 5)
- expected/2 (random.ascii/alpha 5)]
- (`` ($_ _.and
- (~~ (template [<error?> <log!>]
- [(let [console (@version.echo "")
- shell (|> (list expected/0 expected/1 expected/2)
- (..reader_shell <error?>)
- shell.async)]
- (in (do [! async.monad]
- [verdict (do ///action.monad
- [process (shell [environment.empty working_directory "" (list "")])
- _ (<log!> console process)
- actual/0 (# console read_line [])
- actual/1 (# console read_line [])
- actual/2 (# console read_line [])
- end! (|> (# console read_line [])
- (# ! each (|>> (pipe.case
- {try.#Failure error}
- true
-
- {try.#Success _}
- false)
- {try.#Success})))]
- (in (and (text#= expected/0 actual/0)
- (text#= expected/1 actual/1)
- (text#= expected/2 actual/2)
- end!)))]
- (_.cover' [<log!>]
- (try.else false verdict)))))]
+ {try.#Failure error}
+ (exception.match? /.no_available_lux error)))))
+ (do !
+ [.let [console (@version.echo "")]
+ [compiler resolution] ..resolution]
+ (in (do async.monad
+ [verdict (do ///action.monad
+ [_ (/.do! console (program.async (program.mock environment.empty home working_directory))
+ fs shell resolution
+ (has ///.#lux compiler profile))
+ start (# console read_line [])
+ end (# console read_line [])]
+ (in (and (text#= /.start start)
+ (text#= /.success end))))]
+ (_.cover' [/.do!
+ /.lux_group
+ /.jvm_lux_name
+ /.js_lux_name
+ /.python_lux_name
+ /.lua_lux_name
+ /.ruby_lux_name
+ /.start
+ /.success]
+ (try.else false verdict)))))
+ (do !
+ [.let [console (@version.echo "")]
+ [compiler resolution] ..resolution]
+ (in (do async.monad
+ [verdict (do ///action.monad
+ [_ (/.do! console (program.async (program.mock environment.empty home working_directory))
+ fs (shell.async (..bad_shell [])) resolution
+ (has ///.#lux compiler profile))
+ start (# console read_line [])
+ end (# console read_line [])]
+ (in (and (text#= /.start start)
+ (text#= /.failure end))))]
+ (_.cover' [/.failure]
+ (try.else false verdict)))))
+ (do !
+ [expected/0 (random.ascii/alpha 5)
+ expected/1 (random.ascii/alpha 5)
+ expected/2 (random.ascii/alpha 5)]
+ (`` (all _.and
+ (~~ (template [<error?> <log!>]
+ [(let [console (@version.echo "")
+ shell (|> (list expected/0 expected/1 expected/2)
+ (..reader_shell <error?>)
+ shell.async)]
+ (in (do [! async.monad]
+ [verdict (do ///action.monad
+ [process (shell [environment.empty working_directory "" (list "")])
+ _ (<log!> console process)
+ actual/0 (# console read_line [])
+ actual/1 (# console read_line [])
+ actual/2 (# console read_line [])
+ end! (|> (# console read_line [])
+ (# ! each (|>> (pipe.case
+ {try.#Failure error}
+ true
+
+ {try.#Success _}
+ false)
+ {try.#Success})))]
+ (in (and (text#= expected/0 actual/0)
+ (text#= expected/1 actual/1)
+ (text#= expected/2 actual/2)
+ end!)))]
+ (_.cover' [<log!>]
+ (try.else false verdict)))))]
- [#0 /.log_output!]
- [#1 /.log_error!]
- ))
- )))
- ))))
+ [#0 /.log_output!]
+ [#1 /.log_error!]
+ ))
+ )))
+ ))))
diff --git a/stdlib/source/test/aedifex/command/install.lux b/stdlib/source/test/aedifex/command/install.lux
index 414d104d8..d4244bfcf 100644
--- a/stdlib/source/test/aedifex/command/install.lux
+++ b/stdlib/source/test/aedifex/command/install.lux
@@ -70,36 +70,36 @@
home (random.ascii/alpha 5)
working_directory (random.ascii/alpha 5)
.let [/ (# file.default separator)]]
- ($_ _.and
- (in (do [! async.monad]
- [.let [fs (file.mock /)
- program (program.async (program.mock environment.empty home working_directory))
+ (all _.and
+ (in (do [! async.monad]
+ [.let [fs (file.mock /)
+ program (program.async (program.mock environment.empty home working_directory))
- artifact_path (///local.uri (the ///artifact.#version identity) identity)
- library_path (format artifact_path ///artifact/extension.lux_library)
- pom_path (format artifact_path ///artifact/extension.pom)]
- verdict (do [! ///action.monad]
- [succeeded! (# ! each (text#= /.success)
- (..execute! program fs sample))
- library_exists! (|> library_path
- (format home /)
- (# fs file?)
- (# async.monad each (|>> {try.#Success})))
- pom_exists! (|> pom_path
- (format home /)
- (# fs file?)
- (# async.monad each (|>> {try.#Success})))]
- (in (and succeeded!
- library_exists!
- pom_exists!)))]
- (_.cover' [/.do! /.success]
- (try.else false verdict))))
- (in (do [! async.monad]
- [.let [fs (file.mock /)
- program (program.async (program.mock environment.empty home working_directory))]
- logging (..execute! program fs (has ///.#identity {.#None} sample))]
- (_.cover' [/.failure]
- (|> logging
- (try#each (text#= /.failure))
- (try.else false)))))
- ))))
+ artifact_path (///local.uri (the ///artifact.#version identity) identity)
+ library_path (format artifact_path ///artifact/extension.lux_library)
+ pom_path (format artifact_path ///artifact/extension.pom)]
+ verdict (do [! ///action.monad]
+ [succeeded! (# ! each (text#= /.success)
+ (..execute! program fs sample))
+ library_exists! (|> library_path
+ (format home /)
+ (# fs file?)
+ (# async.monad each (|>> {try.#Success})))
+ pom_exists! (|> pom_path
+ (format home /)
+ (# fs file?)
+ (# async.monad each (|>> {try.#Success})))]
+ (in (and succeeded!
+ library_exists!
+ pom_exists!)))]
+ (_.cover' [/.do! /.success]
+ (try.else false verdict))))
+ (in (do [! async.monad]
+ [.let [fs (file.mock /)
+ program (program.async (program.mock environment.empty home working_directory))]
+ logging (..execute! program fs (has ///.#identity {.#None} sample))]
+ (_.cover' [/.failure]
+ (|> logging
+ (try#each (text#= /.failure))
+ (try.else false)))))
+ ))))
diff --git a/stdlib/source/test/aedifex/command/test.lux b/stdlib/source/test/aedifex/command/test.lux
index 4109c99ee..34bd05c36 100644
--- a/stdlib/source/test/aedifex/command/test.lux
+++ b/stdlib/source/test/aedifex/command/test.lux
@@ -58,58 +58,58 @@
with_test
with_target)]
[compiler resolution] @build.resolution]
- ($_ _.and
- (let [fs (file.mock (# file.default separator))
- console (@version.echo "")]
- (in (do async.monad
- [verdict (do ///action.monad
- [_ (/.do! console (program.async (program.mock environment.empty home working_directory))
- fs (shell.async (@build.good_shell [])) resolution
- (has ///.#lux compiler profile))
- build_start (# console read_line [])
- build_end (# console read_line [])
- test_start (# console read_line [])
- test_end (# console read_line [])]
- (in (and (and (text#= //build.start build_start)
- (text#= //build.success build_end))
- (and (text#= /.start test_start)
- (text#= /.success test_end)))))]
- (_.cover' [/.do!
- /.start /.success]
- (try.else false verdict)))))
- (let [fs (file.mock (# file.default separator))
- console (@version.echo "")]
- (in (do async.monad
- [verdict (do ///action.monad
- [.let [bad_shell (shell.mock
- (function (_ [actual_environment actual_working_directory actual_command actual_arguments])
- {try.#Success
- (is (shell.Mock [])
- (implementation
- (def: (on_read state)
- (exception.except shell.no_more_output []))
- (def: (on_fail state)
- (exception.except shell.no_more_output []))
- (def: (on_write input state)
- {try.#Failure "on_write"})
- (def: (on_destroy state)
- {try.#Failure "on_destroy"})
- (def: (on_await state)
- {try.#Success [state (if (list.any? (text#= "build") actual_arguments)
- shell.normal
- shell.error)]})))})
- [])]
- _ (/.do! console (program.async (program.mock environment.empty home working_directory))
- fs (shell.async bad_shell) resolution
- (has ///.#lux compiler profile))
- build_start (# console read_line [])
- build_end (# console read_line [])
- test_start (# console read_line [])
- test_end (# console read_line [])]
- (in (and (and (text#= //build.start build_start)
- (text#= //build.success build_end))
- (and (text#= /.start test_start)
- (text#= /.failure test_end)))))]
- (_.cover' [/.failure]
- (try.else false verdict)))))
- ))))
+ (all _.and
+ (let [fs (file.mock (# file.default separator))
+ console (@version.echo "")]
+ (in (do async.monad
+ [verdict (do ///action.monad
+ [_ (/.do! console (program.async (program.mock environment.empty home working_directory))
+ fs (shell.async (@build.good_shell [])) resolution
+ (has ///.#lux compiler profile))
+ build_start (# console read_line [])
+ build_end (# console read_line [])
+ test_start (# console read_line [])
+ test_end (# console read_line [])]
+ (in (and (and (text#= //build.start build_start)
+ (text#= //build.success build_end))
+ (and (text#= /.start test_start)
+ (text#= /.success test_end)))))]
+ (_.cover' [/.do!
+ /.start /.success]
+ (try.else false verdict)))))
+ (let [fs (file.mock (# file.default separator))
+ console (@version.echo "")]
+ (in (do async.monad
+ [verdict (do ///action.monad
+ [.let [bad_shell (shell.mock
+ (function (_ [actual_environment actual_working_directory actual_command actual_arguments])
+ {try.#Success
+ (is (shell.Mock [])
+ (implementation
+ (def: (on_read state)
+ (exception.except shell.no_more_output []))
+ (def: (on_fail state)
+ (exception.except shell.no_more_output []))
+ (def: (on_write input state)
+ {try.#Failure "on_write"})
+ (def: (on_destroy state)
+ {try.#Failure "on_destroy"})
+ (def: (on_await state)
+ {try.#Success [state (if (list.any? (text#= "build") actual_arguments)
+ shell.normal
+ shell.error)]})))})
+ [])]
+ _ (/.do! console (program.async (program.mock environment.empty home working_directory))
+ fs (shell.async bad_shell) resolution
+ (has ///.#lux compiler profile))
+ build_start (# console read_line [])
+ build_end (# console read_line [])
+ test_start (# console read_line [])
+ test_end (# console read_line [])]
+ (in (and (and (text#= //build.start build_start)
+ (text#= //build.success build_end))
+ (and (text#= /.start test_start)
+ (text#= /.failure test_end)))))]
+ (_.cover' [/.failure]
+ (try.else false verdict)))))
+ ))))
diff --git a/stdlib/source/test/aedifex/dependency.lux b/stdlib/source/test/aedifex/dependency.lux
index b664d70ac..21e90f754 100644
--- a/stdlib/source/test/aedifex/dependency.lux
+++ b/stdlib/source/test/aedifex/dependency.lux
@@ -1,35 +1,35 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]
- ["$[0]" order]
- ["$[0]" hash]]]
- [math
- ["[0]" random {"+" Random}]]]]
- [//
- ["@[0]" artifact]]
- [\\program
- ["[0]" /]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]
+ ["$[0]" order]
+ ["$[0]" hash]]]
+ [math
+ ["[0]" random {"+" Random}]]]]
+ [//
+ ["@[0]" artifact]]
+ [\\program
+ ["[0]" /]])
(def: .public random
(Random /.Dependency)
- ($_ random.and
- @artifact.random
- (random.ascii/alpha 1)))
+ (all random.and
+ @artifact.random
+ (random.ascii/alpha 1)))
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Dependency]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
- (_.for [/.order]
- ($order.spec /.order ..random))
- (_.for [/.hash]
- ($hash.spec /.hash ..random))
- ))))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+ (_.for [/.order]
+ ($order.spec /.order ..random))
+ (_.for [/.hash]
+ ($hash.spec /.hash ..random))
+ ))))
diff --git a/stdlib/source/test/aedifex/dependency/deployment.lux b/stdlib/source/test/aedifex/dependency/deployment.lux
index ed834c759..c52ff5f21 100644
--- a/stdlib/source/test/aedifex/dependency/deployment.lux
+++ b/stdlib/source/test/aedifex/dependency/deployment.lux
@@ -149,56 +149,56 @@
(do [! random.monad]
[address (# ! each (text.suffix uri.separator)
(random.ascii/upper 10))]
- ($_ _.and
- (do [! random.monad]
- [[dependency expected_artifact package] ..bundle
- .let [cache (is Cache
- (atom.atom (dictionary.empty text.hash)))
- http (..http cache)
- repository (repository.async (remote.repository http {.#None} address))]]
- (in (do async.monad
- [?outcome (/.one repository dependency package)
- cache (async.future (atom.read! cache))]
- (_.cover' [/.one]
- (|> ?outcome
- (try#each (verify_one 1 address package cache expected_artifact))
- (try.else false))))))
- (do [! random.monad]
- [.let [hash (is (Hash [Dependency Artifact Package])
- (# hash.functor each (|>> product.right product.left product.left)
- text.hash))]
- num_bundles (# ! each (n.% 10) random.nat)
- bundles (|> ..bundle
- (random.set hash num_bundles)
- (# ! each set.list))
- .let [resolution (list#mix (function (_ [dependency expected_artifact package] resolution)
- (dictionary.has dependency package resolution))
- resolution.empty
- bundles)
- cache (is Cache
- (atom.atom (dictionary.empty text.hash)))
- http (..http cache)
- repository (repository.async (remote.repository http {.#None} address))]]
- (in (do async.monad
- [?outcome (/.all repository resolution)
- cache (async.future (atom.read! cache))]
- (_.cover' [/.all]
- (|> ?outcome
- (try#each (function (_ actual_artifacts)
- (let [expected_deployments!
- (n.= num_bundles (set.size actual_artifacts))
+ (all _.and
+ (do [! random.monad]
+ [[dependency expected_artifact package] ..bundle
+ .let [cache (is Cache
+ (atom.atom (dictionary.empty text.hash)))
+ http (..http cache)
+ repository (repository.async (remote.repository http {.#None} address))]]
+ (in (do async.monad
+ [?outcome (/.one repository dependency package)
+ cache (async.future (atom.read! cache))]
+ (_.cover' [/.one]
+ (|> ?outcome
+ (try#each (verify_one 1 address package cache expected_artifact))
+ (try.else false))))))
+ (do [! random.monad]
+ [.let [hash (is (Hash [Dependency Artifact Package])
+ (# hash.functor each (|>> product.right product.left product.left)
+ text.hash))]
+ num_bundles (# ! each (n.% 10) random.nat)
+ bundles (|> ..bundle
+ (random.set hash num_bundles)
+ (# ! each set.list))
+ .let [resolution (list#mix (function (_ [dependency expected_artifact package] resolution)
+ (dictionary.has dependency package resolution))
+ resolution.empty
+ bundles)
+ cache (is Cache
+ (atom.atom (dictionary.empty text.hash)))
+ http (..http cache)
+ repository (repository.async (remote.repository http {.#None} address))]]
+ (in (do async.monad
+ [?outcome (/.all repository resolution)
+ cache (async.future (atom.read! cache))]
+ (_.cover' [/.all]
+ (|> ?outcome
+ (try#each (function (_ actual_artifacts)
+ (let [expected_deployments!
+ (n.= num_bundles (set.size actual_artifacts))
- every_deployment_was_correct!
- (list.every? (function (_ [dependency expected_artifact package])
- (let [deployed!
- (set.member? actual_artifacts expected_artifact)
+ every_deployment_was_correct!
+ (list.every? (function (_ [dependency expected_artifact package])
+ (let [deployed!
+ (set.member? actual_artifacts expected_artifact)
- deployed_correctly!
- (verify_one num_bundles address package cache expected_artifact expected_artifact)]
- (and deployed!
- deployed_correctly!)))
- bundles)]
- (and expected_deployments!
- every_deployment_was_correct!))))
- (try.else false))))))
- ))))
+ deployed_correctly!
+ (verify_one num_bundles address package cache expected_artifact expected_artifact)]
+ (and deployed!
+ deployed_correctly!)))
+ bundles)]
+ (and expected_deployments!
+ every_deployment_was_correct!))))
+ (try.else false))))))
+ ))))
diff --git a/stdlib/source/test/aedifex/dependency/resolution.lux b/stdlib/source/test/aedifex/dependency/resolution.lux
index c7f81d3c3..bb2411590 100644
--- a/stdlib/source/test/aedifex/dependency/resolution.lux
+++ b/stdlib/source/test/aedifex/dependency/resolution.lux
@@ -257,37 +257,37 @@
.let [good (..single expected_artifact expected_package)
bad_sha-1 (..bad_sha-1 expected_artifact expected_package dummy_package)
bad_md5 (..bad_md5 expected_artifact expected_package dummy_package)]]
- (`` ($_ _.and
- (in (do async.monad
- [actual_package (/.one (///repository.mock good [])
- [///dependency.#artifact expected_artifact
- ///dependency.#type ///artifact/type.lux_library])]
- (_.cover' [/.one]
- (case actual_package
- {try.#Success actual_package}
- (# ///package.equivalence =
- (has ///package.#origin {///repository/origin.#Remote ""} expected_package)
- actual_package)
-
- {try.#Failure _}
- false))))
- (~~ (template [<exception> <bad>]
- [(in (do async.monad
- [actual_package (/.one (///repository.mock <bad> [])
- [///dependency.#artifact expected_artifact
- ///dependency.#type ///artifact/type.lux_library])]
- (_.cover' [<exception>]
- (case actual_package
- {try.#Failure error}
- (exception.match? <exception> error)
-
- {try.#Success _}
- false))))]
-
- [/.sha-1_does_not_match bad_sha-1]
- [/.md5_does_not_match bad_md5]
- ))
- ))))
+ (`` (all _.and
+ (in (do async.monad
+ [actual_package (/.one (///repository.mock good [])
+ [///dependency.#artifact expected_artifact
+ ///dependency.#type ///artifact/type.lux_library])]
+ (_.cover' [/.one]
+ (case actual_package
+ {try.#Success actual_package}
+ (# ///package.equivalence =
+ (has ///package.#origin {///repository/origin.#Remote ""} expected_package)
+ actual_package)
+
+ {try.#Failure _}
+ false))))
+ (~~ (template [<exception> <bad>]
+ [(in (do async.monad
+ [actual_package (/.one (///repository.mock <bad> [])
+ [///dependency.#artifact expected_artifact
+ ///dependency.#type ///artifact/type.lux_library])]
+ (_.cover' [<exception>]
+ (case actual_package
+ {try.#Failure error}
+ (exception.match? <exception> error)
+
+ {try.#Success _}
+ false))))]
+
+ [/.sha-1_does_not_match bad_sha-1]
+ [/.md5_does_not_match bad_md5]
+ ))
+ ))))
(def: any
Test
@@ -302,39 +302,39 @@
.let [good (..single expected_artifact expected_package)
bad_sha-1 (..bad_sha-1 expected_artifact expected_package dummy_package)
bad_md5 (..bad_md5 expected_artifact expected_package dummy_package)]]
- ($_ _.and
- (in (do async.monad
- [.let [console ($///version.echo "")]
- actual_package (/.any console
- (list (///repository.mock bad_sha-1 [])
- (///repository.mock bad_md5 [])
- (///repository.mock good []))
- [///dependency.#artifact expected_artifact
- ///dependency.#type ///artifact/type.lux_library])]
- (_.cover' [/.any]
- (case actual_package
- {try.#Success actual_package}
- (# ///package.equivalence =
- (has ///package.#origin {///repository/origin.#Remote ""} expected_package)
- actual_package)
-
- {try.#Failure _}
- false))))
- (in (do async.monad
- [.let [console ($///version.echo "")]
- actual_package (/.any console
- (list (///repository.mock bad_sha-1 [])
- (///repository.mock bad_md5 []))
- [///dependency.#artifact expected_artifact
- ///dependency.#type ///artifact/type.lux_library])]
- (_.cover' [/.cannot_resolve]
- (case actual_package
- {try.#Failure error}
- (exception.match? /.cannot_resolve error)
-
- {try.#Success _}
- false))))
- )))
+ (all _.and
+ (in (do async.monad
+ [.let [console ($///version.echo "")]
+ actual_package (/.any console
+ (list (///repository.mock bad_sha-1 [])
+ (///repository.mock bad_md5 [])
+ (///repository.mock good []))
+ [///dependency.#artifact expected_artifact
+ ///dependency.#type ///artifact/type.lux_library])]
+ (_.cover' [/.any]
+ (case actual_package
+ {try.#Success actual_package}
+ (# ///package.equivalence =
+ (has ///package.#origin {///repository/origin.#Remote ""} expected_package)
+ actual_package)
+
+ {try.#Failure _}
+ false))))
+ (in (do async.monad
+ [.let [console ($///version.echo "")]
+ actual_package (/.any console
+ (list (///repository.mock bad_sha-1 [])
+ (///repository.mock bad_md5 []))
+ [///dependency.#artifact expected_artifact
+ ///dependency.#type ///artifact/type.lux_library])]
+ (_.cover' [/.cannot_resolve]
+ (case actual_package
+ {try.#Failure error}
+ (exception.match? /.cannot_resolve error)
+
+ {try.#Success _}
+ false))))
+ )))
(def: artifacts
(Random [Artifact Artifact Artifact])
@@ -405,40 +405,40 @@
[[dependee depender ignored]
[dependee_package depender_package ignored_package]]
(..packages [dependee_artifact depender_artifact ignored_artifact])]
- ($_ _.and
- (in (do async.monad
- [.let [console ($///version.echo "")]
- [successes failures resolution] (/.all console
- (list (///repository.mock (..single dependee_artifact dependee_package) [])
- (///repository.mock (..single depender_artifact depender_package) [])
- (///repository.mock (..single ignored_artifact ignored_package) []))
- (function (_ url)
- (///repository.mock ..nope []))
- (list depender)
- /.empty)]
- (_.cover' [/.all]
- (and (dictionary.key? resolution depender)
- (list.any? (///dependency#= depender) successes)
-
- (dictionary.key? resolution dependee)
- (list.any? (///dependency#= dependee) successes)
-
- (list.empty? failures)
- (not (dictionary.key? resolution ignored))))))
- )))
+ (all _.and
+ (in (do async.monad
+ [.let [console ($///version.echo "")]
+ [successes failures resolution] (/.all console
+ (list (///repository.mock (..single dependee_artifact dependee_package) [])
+ (///repository.mock (..single depender_artifact depender_package) [])
+ (///repository.mock (..single ignored_artifact ignored_package) []))
+ (function (_ url)
+ (///repository.mock ..nope []))
+ (list depender)
+ /.empty)]
+ (_.cover' [/.all]
+ (and (dictionary.key? resolution depender)
+ (list.any? (///dependency#= depender) successes)
+
+ (dictionary.key? resolution dependee)
+ (list.any? (///dependency#= dependee) successes)
+
+ (list.empty? failures)
+ (not (dictionary.key? resolution ignored))))))
+ )))
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Resolution])
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
- (_.cover [/.empty]
- (dictionary.empty? /.empty))
+ (_.cover [/.empty]
+ (dictionary.empty? /.empty))
- ..one
- ..any
- ..all
- )))
+ ..one
+ ..any
+ ..all
+ )))
diff --git a/stdlib/source/test/aedifex/dependency/status.lux b/stdlib/source/test/aedifex/dependency/status.lux
index 5008cbb9a..948de489f 100644
--- a/stdlib/source/test/aedifex/dependency/status.lux
+++ b/stdlib/source/test/aedifex/dependency/status.lux
@@ -1,48 +1,48 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]]]
- [data
- ["[0]" binary "_"
- ["[1]T" \\test]]]
- [math
- ["[0]" random {"+" Random} ("[1]#[0]" monad)]]]]
- ["$[0]" /// "_"
- ["[1][0]" hash]]
- [\\program
- ["[0]" /
- ["//[1]" /// "_"
- ["[1][0]" hash]]]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]]]
+ [data
+ ["[0]" binary "_"
+ ["[1]T" \\test]]]
+ [math
+ ["[0]" random {"+" Random} ("[1]#[0]" monad)]]]]
+ ["$[0]" /// "_"
+ ["[1][0]" hash]]
+ [\\program
+ ["[0]" /
+ ["//[1]" /// "_"
+ ["[1][0]" hash]]]])
(def: .public random
(Random /.Status)
- ($_ random.or
- (random#in [])
- (random.or ($///hash.random ///hash.sha-1)
- ($///hash.random ///hash.md5))
- (random.and ($///hash.random ///hash.sha-1)
+ (all random.or
+ (random#in [])
+ (random.or ($///hash.random ///hash.sha-1)
($///hash.random ///hash.md5))
- ))
+ (random.and ($///hash.random ///hash.sha-1)
+ ($///hash.random ///hash.md5))
+ ))
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Status]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
- (do random.monad
- [payload (binaryT.random 1)]
- (_.cover [/.verified]
- (case (/.verified payload)
- {/.#Verified sha1 md5}
- true
+ (do random.monad
+ [payload (binaryT.random 1)]
+ (_.cover [/.verified]
+ (case (/.verified payload)
+ {/.#Verified sha1 md5}
+ true
- _
- false)))
- ))))
+ _
+ false)))
+ ))))
diff --git a/stdlib/source/test/aedifex/hash.lux b/stdlib/source/test/aedifex/hash.lux
index 8f6558cb5..804708085 100644
--- a/stdlib/source/test/aedifex/hash.lux
+++ b/stdlib/source/test/aedifex/hash.lux
@@ -1,29 +1,29 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]
- [\\specification
- ["$[0]" equivalence]
- ["$[0]" codec]]]
- [control
- ["[0]" try]
- ["[0]" exception]]
- [data
- ["[0]" binary {"+" Binary}]
- [text
- ["%" format {"+" format}]]]
- [math
- ["[0]" random {"+" Random}]
- [number
- ["n" nat]]]]]
- [\\program
- ["[0]" /]]
- [test
- [lux
- [data
- ["_[0]" binary]]]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]
+ [\\specification
+ ["$[0]" equivalence]
+ ["$[0]" codec]]]
+ [control
+ ["[0]" try]
+ ["[0]" exception]]
+ [data
+ ["[0]" binary {"+" Binary}]
+ [text
+ ["%" format {"+" format}]]]
+ [math
+ ["[0]" random {"+" Random}]
+ [number
+ ["n" nat]]]]]
+ [\\program
+ ["[0]" /]]
+ [test
+ [lux
+ [data
+ ["_[0]" binary]]]])
(def: .public (random hash)
(All (_ h)
@@ -37,59 +37,59 @@
Test
(<| (_.covering /._)
(_.for [/.Hash /.SHA-1 /.MD5])
- (`` ($_ _.and
- (_.for [/.equivalence]
- ($_ _.and
- ($equivalence.spec /.equivalence (..random /.sha-1))
- ($equivalence.spec /.equivalence (..random /.md5))
- ))
- (_.for [/.data]
- ($_ _.and
- (~~ (template [<hash> <constructor> <exception>]
- [(do random.monad
- [expected (..random <hash>)]
- (_.cover [<hash> <constructor> <exception>]
- (and (case (<constructor> (/.data expected))
- {try.#Success actual}
- (# /.equivalence = expected actual)
+ (`` (all _.and
+ (_.for [/.equivalence]
+ (all _.and
+ ($equivalence.spec /.equivalence (..random /.sha-1))
+ ($equivalence.spec /.equivalence (..random /.md5))
+ ))
+ (_.for [/.data]
+ (all _.and
+ (~~ (template [<hash> <constructor> <exception>]
+ [(do random.monad
+ [expected (..random <hash>)]
+ (_.cover [<hash> <constructor> <exception>]
+ (and (case (<constructor> (/.data expected))
+ {try.#Success actual}
+ (# /.equivalence = expected actual)
- {try.#Failure error}
- false)
- (case (<constructor> (# binary.monoid composite
- (/.data expected)
- (/.data expected)))
- {try.#Success actual}
- false
+ {try.#Failure error}
+ false)
+ (case (<constructor> (# binary.monoid composite
+ (/.data expected)
+ (/.data expected)))
+ {try.#Success actual}
+ false
- {try.#Failure error}
- (exception.match? <exception> error)))))]
+ {try.#Failure error}
+ (exception.match? <exception> error)))))]
- [/.sha-1 /.as_sha-1 /.not_a_sha-1]
- [/.md5 /.as_md5 /.not_a_md5]
- ))))
- (~~ (template [<codec> <hash>]
- [(_.for [<codec>]
- ($codec.spec /.equivalence <codec> (..random <hash>)))]
-
- [/.sha-1_codec /.sha-1]
- [/.md5_codec /.md5]
- ))
- (_.for [/.not_a_hash]
- ($_ _.and
- (~~ (template [<codec> <hash>]
- [(do random.monad
- [expected (..random <hash>)]
- (_.cover [<codec>]
- (case (# <codec> decoded
- (format (# <codec> encoded expected)
- "AABBCC"))
- {try.#Success actual}
- false
+ [/.sha-1 /.as_sha-1 /.not_a_sha-1]
+ [/.md5 /.as_md5 /.not_a_md5]
+ ))))
+ (~~ (template [<codec> <hash>]
+ [(_.for [<codec>]
+ ($codec.spec /.equivalence <codec> (..random <hash>)))]
+
+ [/.sha-1_codec /.sha-1]
+ [/.md5_codec /.md5]
+ ))
+ (_.for [/.not_a_hash]
+ (all _.and
+ (~~ (template [<codec> <hash>]
+ [(do random.monad
+ [expected (..random <hash>)]
+ (_.cover [<codec>]
+ (case (# <codec> decoded
+ (format (# <codec> encoded expected)
+ "AABBCC"))
+ {try.#Success actual}
+ false
- {try.#Failure error}
- (exception.match? /.not_a_hash error))))]
+ {try.#Failure error}
+ (exception.match? /.not_a_hash error))))]
- [/.sha-1_codec /.sha-1]
- [/.md5_codec /.md5]
- ))))
- ))))
+ [/.sha-1_codec /.sha-1]
+ [/.md5_codec /.md5]
+ ))))
+ ))))
diff --git a/stdlib/source/test/aedifex/local.lux b/stdlib/source/test/aedifex/local.lux
index 241915579..c46a1679d 100644
--- a/stdlib/source/test/aedifex/local.lux
+++ b/stdlib/source/test/aedifex/local.lux
@@ -20,8 +20,8 @@
(<| (_.covering /._)
(do [! random.monad]
[sample @artifact.random]
- ($_ _.and
- (_.cover [/.repository /.uri]
- (text.starts_with? /.repository
- (/.uri (the //artifact.#version sample) sample)))
- ))))
+ (all _.and
+ (_.cover [/.repository /.uri]
+ (text.starts_with? /.repository
+ (/.uri (the //artifact.#version sample) sample)))
+ ))))
diff --git a/stdlib/source/test/aedifex/metadata.lux b/stdlib/source/test/aedifex/metadata.lux
index b3176a5c7..5ff5988ee 100644
--- a/stdlib/source/test/aedifex/metadata.lux
+++ b/stdlib/source/test/aedifex/metadata.lux
@@ -1,51 +1,51 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]]
- [data
- ["[0]" text ("[1]#[0]" equivalence)]]
- [math
- ["[0]" random]]]]
- ["[0]" / "_"
- ["[1][0]" artifact]
- ["[1][0]" snapshot]
- [//
- ["$[0]" artifact]]]
- [\\program
- ["[0]" /]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]]
+ [data
+ ["[0]" text ("[1]#[0]" equivalence)]]
+ [math
+ ["[0]" random]]]]
+ ["[0]" / "_"
+ ["[1][0]" artifact]
+ ["[1][0]" snapshot]
+ [//
+ ["$[0]" artifact]]]
+ [\\program
+ ["[0]" /]])
(def: .public test
Test
(<| (_.covering /._)
- ($_ _.and
- (do random.monad
- [sample $artifact.random]
- ($_ _.and
- (_.cover [/.remote_artifact_uri /.remote_project_uri]
- (not (text#= (/.remote_artifact_uri sample)
- (/.remote_project_uri sample))))
- (_.cover [/.local_uri]
- (let [remote_artifact_uri (/.remote_artifact_uri sample)
- remote_project_uri (/.remote_project_uri sample)]
- (and (not (text#= remote_artifact_uri (/.local_uri remote_artifact_uri)))
- (not (text#= remote_project_uri (/.local_uri remote_project_uri))))))
- (_.cover [/.remote_uri]
- (let [remote_artifact_uri (/.remote_artifact_uri sample)
- remote_project_uri (/.remote_project_uri sample)]
- (and (text#= remote_artifact_uri (/.remote_uri remote_artifact_uri))
- (text#= remote_project_uri (/.remote_uri remote_project_uri))
- (|> remote_artifact_uri
- /.local_uri
- /.remote_uri
- (text#= remote_artifact_uri))
- (|> remote_project_uri
- /.local_uri
- /.remote_uri
- (text#= remote_project_uri)))))
- ))
-
- /artifact.test
- /snapshot.test
- )))
+ (all _.and
+ (do random.monad
+ [sample $artifact.random]
+ (all _.and
+ (_.cover [/.remote_artifact_uri /.remote_project_uri]
+ (not (text#= (/.remote_artifact_uri sample)
+ (/.remote_project_uri sample))))
+ (_.cover [/.local_uri]
+ (let [remote_artifact_uri (/.remote_artifact_uri sample)
+ remote_project_uri (/.remote_project_uri sample)]
+ (and (not (text#= remote_artifact_uri (/.local_uri remote_artifact_uri)))
+ (not (text#= remote_project_uri (/.local_uri remote_project_uri))))))
+ (_.cover [/.remote_uri]
+ (let [remote_artifact_uri (/.remote_artifact_uri sample)
+ remote_project_uri (/.remote_project_uri sample)]
+ (and (text#= remote_artifact_uri (/.remote_uri remote_artifact_uri))
+ (text#= remote_project_uri (/.remote_uri remote_project_uri))
+ (|> remote_artifact_uri
+ /.local_uri
+ /.remote_uri
+ (text#= remote_artifact_uri))
+ (|> remote_project_uri
+ /.local_uri
+ /.remote_uri
+ (text#= remote_project_uri)))))
+ ))
+
+ /artifact.test
+ /snapshot.test
+ )))
diff --git a/stdlib/source/test/aedifex/metadata/artifact.lux b/stdlib/source/test/aedifex/metadata/artifact.lux
index bf94bf600..1459a88e5 100644
--- a/stdlib/source/test/aedifex/metadata/artifact.lux
+++ b/stdlib/source/test/aedifex/metadata/artifact.lux
@@ -43,28 +43,28 @@
(def: .public random
(Random /.Metadata)
- ($_ random.and
- (random.ascii/alpha 5)
- (random.ascii/alpha 5)
- (random.list 5 (random.ascii/alpha 5))
- (do [! random.monad]
- [year (# ! each (|>> (n.% 9,000) (n.+ 1,000) .int) random.nat)
- month (# ! each (|>> (n.% 12) (n.+ 1)) random.nat)
- day_of_month (# ! each (|>> (n.% 28) (n.+ 1)) random.nat)
- hour (# ! each (n.% 24) random.nat)
- minute (# ! each (n.% 60) random.nat)
- second (# ! each (n.% 60) random.nat)]
- (in (try.trusted
- (do try.monad
- [year (year.year year)
- month (month.by_number month)
- date (date.date year month day_of_month)
- time (time.time
- [time.#hour hour
- time.#minute minute
- time.#second second
- time.#milli_second 0])]
- (in (instant.of_date_time date time))))))))
+ (all random.and
+ (random.ascii/alpha 5)
+ (random.ascii/alpha 5)
+ (random.list 5 (random.ascii/alpha 5))
+ (do [! random.monad]
+ [year (# ! each (|>> (n.% 9,000) (n.+ 1,000) .int) random.nat)
+ month (# ! each (|>> (n.% 12) (n.+ 1)) random.nat)
+ day_of_month (# ! each (|>> (n.% 28) (n.+ 1)) random.nat)
+ hour (# ! each (n.% 24) random.nat)
+ minute (# ! each (n.% 60) random.nat)
+ second (# ! each (n.% 60) random.nat)]
+ (in (try.trusted
+ (do try.monad
+ [year (year.year year)
+ month (month.by_number month)
+ date (date.date year month day_of_month)
+ time (time.time
+ [time.#hour hour
+ time.#minute minute
+ time.#second second
+ time.#milli_second 0])]
+ (in (instant.of_date_time date time))))))))
(def: .public test
Test
@@ -78,39 +78,39 @@
(the /.#versions)
list.head
(maybe.else ""))]]]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
-
- (do random.monad
- [expected ..random]
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- list
- (<xml>.result /.parser)
- (try#each (# /.equivalence = expected))
- (try.else false))))
- (_.cover [/.uri]
- (text#= (//.remote_project_uri artifact)
- (/.uri artifact)))
- (do random.monad
- [home (random.ascii/lower 5)
- working_directory (random.ascii/lower 5)
- .let [program (program.async (program.mock environment.empty home working_directory))
- fs (file.mock (# file.default separator))
- repository (///repository/local.repository program fs)]]
- (in (do async.monad
- [wrote? (/.write repository artifact expected)
- actual (/.read repository artifact)]
- (_.cover' [/.write /.read]
- (and (case wrote?
- {try.#Success _} true
- {try.#Failure _} false)
- (case actual
- {try.#Success actual}
- (# /.equivalence = expected actual)
-
- {try.#Failure _}
- false))))))
- ))))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+
+ (do random.monad
+ [expected ..random]
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ list
+ (<xml>.result /.parser)
+ (try#each (# /.equivalence = expected))
+ (try.else false))))
+ (_.cover [/.uri]
+ (text#= (//.remote_project_uri artifact)
+ (/.uri artifact)))
+ (do random.monad
+ [home (random.ascii/lower 5)
+ working_directory (random.ascii/lower 5)
+ .let [program (program.async (program.mock environment.empty home working_directory))
+ fs (file.mock (# file.default separator))
+ repository (///repository/local.repository program fs)]]
+ (in (do async.monad
+ [wrote? (/.write repository artifact expected)
+ actual (/.read repository artifact)]
+ (_.cover' [/.write /.read]
+ (and (case wrote?
+ {try.#Success _} true
+ {try.#Failure _} false)
+ (case actual
+ {try.#Success actual}
+ (# /.equivalence = expected actual)
+
+ {try.#Failure _}
+ false))))))
+ ))))
diff --git a/stdlib/source/test/aedifex/metadata/snapshot.lux b/stdlib/source/test/aedifex/metadata/snapshot.lux
index 4735a6994..bb862dca2 100644
--- a/stdlib/source/test/aedifex/metadata/snapshot.lux
+++ b/stdlib/source/test/aedifex/metadata/snapshot.lux
@@ -72,18 +72,18 @@
(def: random_versioning
(Random Versioning)
- ($_ random.and
- (random#in {///snapshot.#Local})
- $///artifact/time.random
- (random.list 5 $///artifact/snapshot/version.random)
- ))
+ (all random.and
+ (random#in {///snapshot.#Local})
+ $///artifact/time.random
+ (random.list 5 $///artifact/snapshot/version.random)
+ ))
(def: .public random
(Random /.Metadata)
- ($_ random.and
- $///artifact.random
- ..random_versioning
- ))
+ (all random.and
+ $///artifact.random
+ ..random_versioning
+ ))
(def: .public test
Test
@@ -92,37 +92,37 @@
(do random.monad
[expected ..random
.let [artifact (the /.#artifact expected)]]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
-
- (_.cover [/.format /.parser]
- (|> expected
- /.format
- list
- (<xml>.result /.parser)
- (try#each (# /.equivalence = expected))
- (try.else false)))
- (_.cover [/.uri]
- (text#= (//.remote_artifact_uri artifact)
- (/.uri artifact)))
- (do random.monad
- [home (random.ascii/lower 5)
- working_directory (random.ascii/lower 5)
- .let [program (program.async (program.mock environment.empty home working_directory))
- fs (file.mock (# file.default separator))
- repository (///repository/local.repository program fs)]]
- (in (do async.monad
- [wrote? (/.write repository artifact expected)
- actual (/.read repository artifact)]
- (_.cover' [/.write /.read]
- (and (case wrote?
- {try.#Success _} true
- {try.#Failure _} false)
- (case actual
- {try.#Success actual}
- (# /.equivalence = expected actual)
-
- {try.#Failure _}
- false))))))
- ))))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+
+ (_.cover [/.format /.parser]
+ (|> expected
+ /.format
+ list
+ (<xml>.result /.parser)
+ (try#each (# /.equivalence = expected))
+ (try.else false)))
+ (_.cover [/.uri]
+ (text#= (//.remote_artifact_uri artifact)
+ (/.uri artifact)))
+ (do random.monad
+ [home (random.ascii/lower 5)
+ working_directory (random.ascii/lower 5)
+ .let [program (program.async (program.mock environment.empty home working_directory))
+ fs (file.mock (# file.default separator))
+ repository (///repository/local.repository program fs)]]
+ (in (do async.monad
+ [wrote? (/.write repository artifact expected)
+ actual (/.read repository artifact)]
+ (_.cover' [/.write /.read]
+ (and (case wrote?
+ {try.#Success _} true
+ {try.#Failure _} false)
+ (case actual
+ {try.#Success actual}
+ (# /.equivalence = expected actual)
+
+ {try.#Failure _}
+ false))))))
+ ))))
diff --git a/stdlib/source/test/aedifex/package.lux b/stdlib/source/test/aedifex/package.lux
index af51453dd..28d763e4c 100644
--- a/stdlib/source/test/aedifex/package.lux
+++ b/stdlib/source/test/aedifex/package.lux
@@ -59,64 +59,64 @@
(_.for [/.Package])
(do [! random.monad]
[[profile package] ..random]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence (# ! each product.right ..random)))
-
- (_.cover [/.local?]
- (/.local? (has /.#origin {//origin.#Local "~/yolo"} package)))
- (_.cover [/.remote?]
- (/.remote? (has /.#origin {//origin.#Remote "https://example.com"} package)))
- (_.cover [/.local]
- (let [expected_pom (|> package (the /.#pom) product.left)
- expected_library (|> package (the /.#library) product.left)
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence (# ! each product.right ..random)))
+
+ (_.cover [/.local?]
+ (/.local? (has /.#origin {//origin.#Local "~/yolo"} package)))
+ (_.cover [/.remote?]
+ (/.remote? (has /.#origin {//origin.#Remote "https://example.com"} package)))
+ (_.cover [/.local]
+ (let [expected_pom (|> package (the /.#pom) product.left)
+ expected_library (|> package (the /.#library) product.left)
- local (/.local expected_pom expected_library)
+ local (/.local expected_pom expected_library)
- [actual_pom binary_pom pom_status] (the /.#pom local)
- [actual_library library_status] (the /.#library local)]
- (and (case (the /.#origin local)
- {//origin.#Local ""} true
- _ false)
- (let [expected_sha1 (//hash.sha-1 expected_library)
- expected_md5 (//hash.md5 expected_library)]
- (and (same? expected_library actual_library)
- (case library_status
- {//status.#Verified actual_sha1 expected_md5}
- (and (//hash#= expected_sha1 actual_sha1)
- (//hash#= expected_md5 expected_md5))
-
- _
- false)))
- (let [expected_sha1 (//hash.sha-1 binary_pom)
- expected_md5 (//hash.md5 binary_pom)]
- (and (same? expected_pom actual_pom)
- (|> (do try.monad
- [xml_pom (# utf8.codec decoded binary_pom)
- decoded_pom (# xml.codec decoded xml_pom)]
- (in (# xml.equivalence = actual_pom decoded_pom)))
- (try.else false))
- (case pom_status
- {//status.#Verified actual_sha1 expected_md5}
- (and (//hash#= expected_sha1 actual_sha1)
- (//hash#= expected_md5 expected_md5))
-
- _
- false))))))
- (_.cover [/.dependencies]
- (let [expected (the //.#dependencies profile)]
- (case (/.dependencies package)
- {try.#Success actual}
- (# set.equivalence = expected actual)
-
- {try.#Failure error}
- false)))
- (_.cover [/.repositories]
- (let [expected (the //.#repositories profile)]
- (case (/.repositories package)
- {try.#Success actual}
- (# set.equivalence = expected actual)
-
- {try.#Failure error}
- false)))
- ))))
+ [actual_pom binary_pom pom_status] (the /.#pom local)
+ [actual_library library_status] (the /.#library local)]
+ (and (case (the /.#origin local)
+ {//origin.#Local ""} true
+ _ false)
+ (let [expected_sha1 (//hash.sha-1 expected_library)
+ expected_md5 (//hash.md5 expected_library)]
+ (and (same? expected_library actual_library)
+ (case library_status
+ {//status.#Verified actual_sha1 expected_md5}
+ (and (//hash#= expected_sha1 actual_sha1)
+ (//hash#= expected_md5 expected_md5))
+
+ _
+ false)))
+ (let [expected_sha1 (//hash.sha-1 binary_pom)
+ expected_md5 (//hash.md5 binary_pom)]
+ (and (same? expected_pom actual_pom)
+ (|> (do try.monad
+ [xml_pom (# utf8.codec decoded binary_pom)
+ decoded_pom (# xml.codec decoded xml_pom)]
+ (in (# xml.equivalence = actual_pom decoded_pom)))
+ (try.else false))
+ (case pom_status
+ {//status.#Verified actual_sha1 expected_md5}
+ (and (//hash#= expected_sha1 actual_sha1)
+ (//hash#= expected_md5 expected_md5))
+
+ _
+ false))))))
+ (_.cover [/.dependencies]
+ (let [expected (the //.#dependencies profile)]
+ (case (/.dependencies package)
+ {try.#Success actual}
+ (# set.equivalence = expected actual)
+
+ {try.#Failure error}
+ false)))
+ (_.cover [/.repositories]
+ (let [expected (the //.#repositories profile)]
+ (case (/.repositories package)
+ {try.#Success actual}
+ (# set.equivalence = expected actual)
+
+ {try.#Failure error}
+ false)))
+ ))))
diff --git a/stdlib/source/test/aedifex/pom.lux b/stdlib/source/test/aedifex/pom.lux
index e6d5340e2..bf29cfeb5 100644
--- a/stdlib/source/test/aedifex/pom.lux
+++ b/stdlib/source/test/aedifex/pom.lux
@@ -25,33 +25,33 @@
(def: .public test
Test
(<| (_.covering /._)
- ($_ _.and
- (_.cover [/.file]
- (|> /.file
- (text#= "")
- not))
- (do random.monad
- [expected @profile.random]
- (_.cover [/.write /.parser]
- (case [(/.write expected)
- (the //.#identity expected)]
- [{try.#Success pom}
- {.#Some _}]
- (case (<xml>.result /.parser (list pom))
- {try.#Success actual}
- (# //.equivalence =
- (|> (# //.monoid identity)
- (has //.#dependencies (the //.#dependencies expected))
- (has //.#repositories (the //.#repositories expected)))
- actual)
+ (all _.and
+ (_.cover [/.file]
+ (|> /.file
+ (text#= "")
+ not))
+ (do random.monad
+ [expected @profile.random]
+ (_.cover [/.write /.parser]
+ (case [(/.write expected)
+ (the //.#identity expected)]
+ [{try.#Success pom}
+ {.#Some _}]
+ (case (<xml>.result /.parser (list pom))
+ {try.#Success actual}
+ (# //.equivalence =
+ (|> (# //.monoid identity)
+ (has //.#dependencies (the //.#dependencies expected))
+ (has //.#repositories (the //.#repositories expected)))
+ actual)
- {try.#Failure error}
- false)
+ {try.#Failure error}
+ false)
- [{try.#Failure error}
- {.#None}]
- (exception.match? //.no_identity error)
+ [{try.#Failure error}
+ {.#None}]
+ (exception.match? //.no_identity error)
- _
- false)))
- )))
+ _
+ false)))
+ )))
diff --git a/stdlib/source/test/aedifex/profile.lux b/stdlib/source/test/aedifex/profile.lux
index e674942e0..246492587 100644
--- a/stdlib/source/test/aedifex/profile.lux
+++ b/stdlib/source/test/aedifex/profile.lux
@@ -46,10 +46,10 @@
(def: license
(Random /.License)
- ($_ random.and
- (random.ascii/alpha 1)
- (random.ascii/alpha 1)
- ..distribution))
+ (all random.and
+ (random.ascii/alpha 1)
+ (random.ascii/alpha 1)
+ ..distribution))
(def: scm
(Random /.SCM)
@@ -57,9 +57,9 @@
(def: organization
(Random /.Organization)
- ($_ random.and
- (random.ascii/alpha 1)
- (random.ascii/alpha 1)))
+ (all random.and
+ (random.ascii/alpha 1)
+ (random.ascii/alpha 1)))
(def: email
(Random /.Email)
@@ -67,10 +67,10 @@
(def: developer
(Random /.Developer)
- ($_ random.and
- (random.ascii/alpha 1)
- (random.ascii/alpha 1)
- (random.maybe organization)))
+ (all random.and
+ (random.ascii/alpha 1)
+ (random.ascii/alpha 1)
+ (random.maybe organization)))
(def: contributor
(Random /.Contributor)
@@ -96,16 +96,16 @@
(def: info
(Random /.Info)
- ($_ random.and
- (random.maybe (random.ascii/alpha 1))
- (random.maybe (random.ascii/alpha 2))
- (random.maybe ..scm)
- (random.maybe (random.ascii/alpha 3))
- (..list_of ..license)
- (random.maybe ..organization)
- (..list_of ..developer)
- (..list_of ..contributor)
- ))
+ (all random.and
+ (random.maybe (random.ascii/alpha 1))
+ (random.maybe (random.ascii/alpha 2))
+ (random.maybe ..scm)
+ (random.maybe (random.ascii/alpha 3))
+ (..list_of ..license)
+ (random.maybe ..organization)
+ (..list_of ..developer)
+ (..list_of ..contributor)
+ ))
(def: name
(Random /.Name)
@@ -125,27 +125,27 @@
(def: .public random
(Random /.Profile)
- ($_ random.and
- (..list_of ..name)
- (random.maybe @artifact.random)
- (random.maybe ..info)
- (..set_of text.hash ..repository)
- (..set_of //dependency.hash @dependency.random)
- @dependency.random
- (..list_of $compiler.random)
- (..set_of text.hash ..source)
- ..target
- (random.maybe (random.ascii/alpha 1))
- (random.maybe (random.ascii/alpha 2))
- (..dictionary_of text.hash (random.ascii/alpha 3) ..repository)
- (..list_of (random.and (random.ascii/alpha 4)
- (random.ascii/alpha 5)))
- (random#in //runtime.default_java)
- (random#in //runtime.default_js)
- (random#in //runtime.default_python)
- (random#in //runtime.default_lua)
- (random#in //runtime.default_ruby)
- ))
+ (all random.and
+ (..list_of ..name)
+ (random.maybe @artifact.random)
+ (random.maybe ..info)
+ (..set_of text.hash ..repository)
+ (..set_of //dependency.hash @dependency.random)
+ @dependency.random
+ (..list_of $compiler.random)
+ (..set_of text.hash ..source)
+ ..target
+ (random.maybe (random.ascii/alpha 1))
+ (random.maybe (random.ascii/alpha 2))
+ (..dictionary_of text.hash (random.ascii/alpha 3) ..repository)
+ (..list_of (random.and (random.ascii/alpha 4)
+ (random.ascii/alpha 5)))
+ (random#in //runtime.default_java)
+ (random#in //runtime.default_js)
+ (random#in //runtime.default_python)
+ (random#in //runtime.default_lua)
+ (random#in //runtime.default_ruby)
+ ))
(def: .public test
Test
@@ -153,20 +153,20 @@
(_.for [/.Distribution /.License /.SCM /.Organization
/.Email /.Developer /.Contributor /.Info
/.Source /.Target /.Name /.Profile]
- (`` ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
- (_.for [/.monoid]
- ($monoid.spec /.equivalence /.monoid ..random))
-
- (_.cover [/.default]
- (text#= "" /.default))
- (_.cover [/.default_lux]
- (|> (# /.monoid identity)
- (the /.#lux)
- (same? /.default_lux)))
- (_.cover [/.default_target]
- (|> (# /.monoid identity)
- (the /.#target)
- (same? /.default_target)))
- )))))
+ (`` (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+ (_.for [/.monoid]
+ ($monoid.spec /.equivalence /.monoid ..random))
+
+ (_.cover [/.default]
+ (text#= "" /.default))
+ (_.cover [/.default_lux]
+ (|> (# /.monoid identity)
+ (the /.#lux)
+ (same? /.default_lux)))
+ (_.cover [/.default_target]
+ (|> (# /.monoid identity)
+ (the /.#target)
+ (same? /.default_target)))
+ )))))
diff --git a/stdlib/source/test/aedifex/project.lux b/stdlib/source/test/aedifex/project.lux
index c7bbe62c0..cf3a93e52 100644
--- a/stdlib/source/test/aedifex/project.lux
+++ b/stdlib/source/test/aedifex/project.lux
@@ -40,61 +40,61 @@
Test
(<| (_.covering /._)
(_.for [/.Project /.project]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
- (_.for [/.monoid]
- ($monoid.spec /.equivalence /.monoid ..random))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+ (_.for [/.monoid]
+ ($monoid.spec /.equivalence /.monoid ..random))
- (_.cover [/.file]
- (|> /.file
- (text#= "")
- not))
- (do random.monad
- [[super_name super_profile] ..profile
- [dummy_name dummy_profile] (random.only (|>> product.left (text#= super_name) not)
- ..profile)
- [sub_name sub_profile] (random.only (function (_ [name profile])
- (and (not (text#= super_name name))
- (not (text#= dummy_name name))))
- ..profile)
- fake_name (random.only (function (_ name)
- (and (not (text#= super_name name))
- (not (text#= dummy_name name))
- (not (text#= sub_name name))))
- (random.ascii/alpha 1))
- .let [project ($_ (# /.monoid composite)
- (/.project super_name super_profile)
- (/.project dummy_name dummy_profile)
- (/.project sub_name (has //.#parents (list super_name) sub_profile)))
- circular ($_ (# /.monoid composite)
- (/.project super_name (has //.#parents (list sub_name) super_profile))
- (/.project dummy_name dummy_profile)
- (/.project sub_name (has //.#parents (list super_name) sub_profile)))]]
- ($_ _.and
- (_.cover [/.profile]
- (and (|> (/.profile project super_name)
- (try#each (# //.equivalence = super_profile))
- (try.else false))
- (|> (/.profile project dummy_name)
- (try#each (# //.equivalence = dummy_profile))
- (try.else false))
- (|> (/.profile project sub_name)
- (try#each (# //.equivalence = (# //.monoid composite sub_profile super_profile)))
- (try.else false))))
- (_.cover [/.unknown_profile]
- (case (/.profile project fake_name)
- {try.#Success _}
- false
+ (_.cover [/.file]
+ (|> /.file
+ (text#= "")
+ not))
+ (do random.monad
+ [[super_name super_profile] ..profile
+ [dummy_name dummy_profile] (random.only (|>> product.left (text#= super_name) not)
+ ..profile)
+ [sub_name sub_profile] (random.only (function (_ [name profile])
+ (and (not (text#= super_name name))
+ (not (text#= dummy_name name))))
+ ..profile)
+ fake_name (random.only (function (_ name)
+ (and (not (text#= super_name name))
+ (not (text#= dummy_name name))
+ (not (text#= sub_name name))))
+ (random.ascii/alpha 1))
+ .let [project (all (# /.monoid composite)
+ (/.project super_name super_profile)
+ (/.project dummy_name dummy_profile)
+ (/.project sub_name (has //.#parents (list super_name) sub_profile)))
+ circular (all (# /.monoid composite)
+ (/.project super_name (has //.#parents (list sub_name) super_profile))
+ (/.project dummy_name dummy_profile)
+ (/.project sub_name (has //.#parents (list super_name) sub_profile)))]]
+ (all _.and
+ (_.cover [/.profile]
+ (and (|> (/.profile project super_name)
+ (try#each (# //.equivalence = super_profile))
+ (try.else false))
+ (|> (/.profile project dummy_name)
+ (try#each (# //.equivalence = dummy_profile))
+ (try.else false))
+ (|> (/.profile project sub_name)
+ (try#each (# //.equivalence = (# //.monoid composite sub_profile super_profile)))
+ (try.else false))))
+ (_.cover [/.unknown_profile]
+ (case (/.profile project fake_name)
+ {try.#Success _}
+ false
- {try.#Failure error}
- (exception.match? /.unknown_profile error)))
- (_.cover [/.circular_dependency]
- (case (/.profile circular sub_name)
- {try.#Success _}
- false
+ {try.#Failure error}
+ (exception.match? /.unknown_profile error)))
+ (_.cover [/.circular_dependency]
+ (case (/.profile circular sub_name)
+ {try.#Success _}
+ false
- {try.#Failure error}
- (exception.match? /.circular_dependency error)))
- ))
- ))))
+ {try.#Failure error}
+ (exception.match? /.circular_dependency error)))
+ ))
+ ))))
diff --git a/stdlib/source/test/aedifex/repository.lux b/stdlib/source/test/aedifex/repository.lux
index b4009cea9..80d3f43e9 100644
--- a/stdlib/source/test/aedifex/repository.lux
+++ b/stdlib/source/test/aedifex/repository.lux
@@ -87,21 +87,21 @@
(def: .public test
Test
(<| (_.covering /._)
- ($_ _.and
- (_.for [/.mock /.Mock]
- (do random.monad
- [_ (in [])]
- ($/.spec (..artifact ..valid_version)
- (..artifact ..invalid_version)
- (/.mock ..mock
- (|> ..empty
- (dictionary.has (remote.uri ..invalid_version
- (..artifact ..invalid_version)
- //artifact/extension.lux_library)
- (binary.empty 0)))))))
+ (all _.and
+ (_.for [/.mock /.Mock]
+ (do random.monad
+ [_ (in [])]
+ ($/.spec (..artifact ..valid_version)
+ (..artifact ..invalid_version)
+ (/.mock ..mock
+ (|> ..empty
+ (dictionary.has (remote.uri ..invalid_version
+ (..artifact ..invalid_version)
+ //artifact/extension.lux_library)
+ (binary.empty 0)))))))
- /identity.test
- /origin.test
- /local.test
- /remote.test
- )))
+ /identity.test
+ /origin.test
+ /local.test
+ /remote.test
+ )))
diff --git a/stdlib/source/test/aedifex/repository/identity.lux b/stdlib/source/test/aedifex/repository/identity.lux
index 90a2e1681..5e357ecca 100644
--- a/stdlib/source/test/aedifex/repository/identity.lux
+++ b/stdlib/source/test/aedifex/repository/identity.lux
@@ -1,27 +1,27 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [\\specification
- ["$[0]" equivalence]]]
- [math
- ["[0]" random {"+" Random}]]]]
- [\\program
- ["[0]" /]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [\\specification
+ ["$[0]" equivalence]]]
+ [math
+ ["[0]" random {"+" Random}]]]]
+ [\\program
+ ["[0]" /]])
(def: .public random
(Random /.Identity)
- ($_ random.and
- (random.ascii/alpha 10)
- (random.ascii/alpha 10)
- ))
+ (all random.and
+ (random.ascii/alpha 10)
+ (random.ascii/alpha 10)
+ ))
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.User /.Password /.Identity]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
- ))))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+ ))))
diff --git a/stdlib/source/test/aedifex/repository/local.lux b/stdlib/source/test/aedifex/repository/local.lux
index f3b8fed6b..c5da9011d 100644
--- a/stdlib/source/test/aedifex/repository/local.lux
+++ b/stdlib/source/test/aedifex/repository/local.lux
@@ -1,27 +1,27 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [monad {"+" do}]]
- [control
- ["[0]" try ("[1]#[0]" functor)]
- [parser
- ["[0]" environment]]
- [concurrency
- ["[0]" async]]]
- [data
- ["[0]" binary ("[1]#[0]" equivalence)]
- [text
- [encoding
- ["[0]" utf8]]]]
- [math
- ["[0]" random]]
- [world
- ["[0]" file]
- ["[0]" program]]]]
- [\\program
- ["[0]" /]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [monad {"+" do}]]
+ [control
+ ["[0]" try ("[1]#[0]" functor)]
+ [parser
+ ["[0]" environment]]
+ [concurrency
+ ["[0]" async]]]
+ [data
+ ["[0]" binary ("[1]#[0]" equivalence)]
+ [text
+ [encoding
+ ["[0]" utf8]]]]
+ [math
+ ["[0]" random]]
+ [world
+ ["[0]" file]
+ ["[0]" program]]]]
+ [\\program
+ ["[0]" /]])
(def: .public test
Test
@@ -37,16 +37,16 @@
uri (random.ascii/lower 10)
expected (# ! each (# utf8.codec encoded)
(random.ascii/lower 10))]
- ($_ _.and
- (in (do async.monad
- [before_upload (# repo download uri)
- _ (# repo upload uri expected)
- actual (# repo download uri)]
- (_.cover' [/.repository]
- (and (case before_upload
- {try.#Success _} false
- {try.#Failure _} true)
- (|> actual
- (try#each (binary#= expected))
- (try.else false))))))
- ))))
+ (all _.and
+ (in (do async.monad
+ [before_upload (# repo download uri)
+ _ (# repo upload uri expected)
+ actual (# repo download uri)]
+ (_.cover' [/.repository]
+ (and (case before_upload
+ {try.#Success _} false
+ {try.#Failure _} true)
+ (|> actual
+ (try#each (binary#= expected))
+ (try.else false))))))
+ ))))
diff --git a/stdlib/source/test/aedifex/repository/origin.lux b/stdlib/source/test/aedifex/repository/origin.lux
index cabea3904..a0bcff68d 100644
--- a/stdlib/source/test/aedifex/repository/origin.lux
+++ b/stdlib/source/test/aedifex/repository/origin.lux
@@ -1,27 +1,27 @@
(.using
- [library
- [lux "*"
- ["_" test {"+" Test}]
- [abstract
- [\\specification
- ["$[0]" equivalence]]]
- [math
- ["[0]" random {"+" Random}]]]]
- [\\program
- ["[0]" /]])
+ [library
+ [lux "*"
+ ["_" test {"+" Test}]
+ [abstract
+ [\\specification
+ ["$[0]" equivalence]]]
+ [math
+ ["[0]" random {"+" Random}]]]]
+ [\\program
+ ["[0]" /]])
(def: .public random
(Random /.Origin)
- ($_ random.or
- (random.ascii/alpha 10)
- (random.ascii/alpha 10)
- ))
+ (all random.or
+ (random.ascii/alpha 10)
+ (random.ascii/alpha 10)
+ ))
(def: .public test
Test
(<| (_.covering /._)
(_.for [/.Origin]
- ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
- ))))
+ (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+ ))))
diff --git a/stdlib/source/test/aedifex/repository/remote.lux b/stdlib/source/test/aedifex/repository/remote.lux
index bd2e68612..abf123f4b 100644
--- a/stdlib/source/test/aedifex/repository/remote.lux
+++ b/stdlib/source/test/aedifex/repository/remote.lux
@@ -92,40 +92,40 @@
content (# ! each (# utf8.codec encoded)
(random.ascii/lower 10))]
- ($_ _.and
- (_.cover [/.repository /.user_agent /.Address]
- (let [repo (/.repository (..good_http user password)
- {.#Some [//identity.#user user
- //identity.#password password]}
- address)]
- (and (|> (# repo download uri)
- io.run!
- (try#each (# utf8.codec decoded))
- try#conjoint
- (try#each (text#= (format address uri)))
- (try.else false))
- (|> (# repo upload uri content)
- io.run!
- (try#each (function.constant true))
- (try.else false)))))
- (_.cover [/.upload_failure]
- (let [repo (/.repository (..good_http user password)
- {.#None}
- address)]
- (case (io.run! (# repo upload uri content))
- {try.#Failure error}
- (exception.match? /.upload_failure error)
-
- {try.#Success _}
- false)))
- (_.cover [/.download_failure]
- (let [repo (/.repository ..bad_http
- {.#None}
- address)]
- (case (io.run! (# repo download uri))
- {try.#Failure error}
- (exception.match? /.download_failure error)
-
- {try.#Success _}
- false)))
- ))))
+ (all _.and
+ (_.cover [/.repository /.user_agent /.Address]
+ (let [repo (/.repository (..good_http user password)
+ {.#Some [//identity.#user user
+ //identity.#password password]}
+ address)]
+ (and (|> (# repo download uri)
+ io.run!
+ (try#each (# utf8.codec decoded))
+ try#conjoint
+ (try#each (text#= (format address uri)))
+ (try.else false))
+ (|> (# repo upload uri content)
+ io.run!
+ (try#each (function.constant true))
+ (try.else false)))))
+ (_.cover [/.upload_failure]
+ (let [repo (/.repository (..good_http user password)
+ {.#None}
+ address)]
+ (case (io.run! (# repo upload uri content))
+ {try.#Failure error}
+ (exception.match? /.upload_failure error)
+
+ {try.#Success _}
+ false)))
+ (_.cover [/.download_failure]
+ (let [repo (/.repository ..bad_http
+ {.#None}
+ address)]
+ (case (io.run! (# repo download uri))
+ {try.#Failure error}
+ (exception.match? /.download_failure error)
+
+ {try.#Success _}
+ false)))
+ ))))
diff --git a/stdlib/source/test/aedifex/runtime.lux b/stdlib/source/test/aedifex/runtime.lux
index 99c1bd92d..5166968f3 100644
--- a/stdlib/source/test/aedifex/runtime.lux
+++ b/stdlib/source/test/aedifex/runtime.lux
@@ -22,13 +22,13 @@
(def: .public random
(Random /.Runtime)
- ($_ random.either
- (random#in /.default_java)
- (random#in /.default_js)
- (random#in /.default_python)
- (random#in /.default_lua)
- (random#in /.default_ruby)
- ))
+ (all random.either
+ (random#in /.default_java)
+ (random#in /.default_js)
+ (random#in /.default_python)
+ (random#in /.default_lua)
+ (random#in /.default_ruby)
+ ))
(def: .public test
Test
@@ -37,31 +37,31 @@
(do random.monad
[path (random.ascii/alpha 5)
runtime ..random]
- (`` ($_ _.and
- (_.for [/.equivalence]
- ($equivalence.spec /.equivalence ..random))
-
- (~~ (template [<command>]
- [(_.cover [/.default_java /.default_js /.default_python /.default_lua /.default_ruby]
- (let [listing (|> (list /.default_java /.default_js /.default_python /.default_lua /.default_ruby)
- (list#each (the /.#program)))
- unique (set.of_list text.hash listing)]
- (n.= (list.size listing)
- (set.size unique))))]
+ (`` (all _.and
+ (_.for [/.equivalence]
+ ($equivalence.spec /.equivalence ..random))
+
+ (~~ (template [<command>]
+ [(_.cover [/.default_java /.default_js /.default_python /.default_lua /.default_ruby]
+ (let [listing (|> (list /.default_java /.default_js /.default_python /.default_lua /.default_ruby)
+ (list#each (the /.#program)))
+ unique (set.of_list text.hash listing)]
+ (n.= (list.size listing)
+ (set.size unique))))]
- [/.default_java]
- [/.default_js]
- [/.default_python]
- [/.default_lua]
- [/.default_ruby]
- ))
- (_.cover [/.for]
- (let [runtime' (/.for runtime path)]
- (and (text#= (the /.#program runtime)
- (the /.#program runtime'))
- (|> runtime'
- (the /.#parameters)
- list.last
- (maybe#each (text#= path))
- (maybe.else false)))))
- )))))
+ [/.default_java]
+ [/.default_js]
+ [/.default_python]
+ [/.default_lua]
+ [/.default_ruby]
+ ))
+ (_.cover [/.for]
+ (let [runtime' (/.for runtime path)]
+ (and (text#= (the /.#program runtime)
+ (the /.#program runtime'))
+ (|> runtime'
+ (the /.#parameters)
+ list.last
+ (maybe#each (text#= path))
+ (maybe.else false)))))
+ )))))