aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/test/aedifex/metadata/snapshot.lux
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/source/test/aedifex/metadata/snapshot.lux')
-rw-r--r--stdlib/source/test/aedifex/metadata/snapshot.lux86
1 files changed, 43 insertions, 43 deletions
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))))))
+ ))))