aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/test/aedifex
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--stdlib/source/test/aedifex.lux8
-rw-r--r--stdlib/source/test/aedifex/parser.lux15
-rw-r--r--stdlib/source/test/aedifex/pom.lux5
3 files changed, 18 insertions, 10 deletions
diff --git a/stdlib/source/test/aedifex.lux b/stdlib/source/test/aedifex.lux
index 8757242c5..477ae4d50 100644
--- a/stdlib/source/test/aedifex.lux
+++ b/stdlib/source/test/aedifex.lux
@@ -16,10 +16,10 @@
["#." local]
["#." metadata]
["#." package]
+ ["#." parser]
+ ["#." pom]
["#." profile]
["#." project]
- ## ["#." parser]
- ## ["#." pom]
## ["#." repository]
## ["#." runtime]
])
@@ -44,11 +44,11 @@
/local.test
/metadata.test
/package.test
+ /parser.test
+ /pom.test
/profile.test
/project.test
- ## /parser.test
- ## /pom.test
## /repository.test
## /runtime.test
))
diff --git a/stdlib/source/test/aedifex/parser.lux b/stdlib/source/test/aedifex/parser.lux
index 0a13acb32..07c426ebb 100644
--- a/stdlib/source/test/aedifex/parser.lux
+++ b/stdlib/source/test/aedifex/parser.lux
@@ -8,7 +8,7 @@
[pipe (#+ case>)]
["." try]
[parser
- ["<c>" code]]]
+ ["<.>" code]]]
[data
["." text]
[collection
@@ -61,6 +61,10 @@
(set.from_list text.hash (list //.default_source))
sources)))))
+(def: with_default_repository
+ (-> //.Profile //.Profile)
+ (update@ #//.repositories (set.add //.default_repository)))
+
(def: single_profile
Test
(do random.monad
@@ -69,10 +73,11 @@
(|> expected
//format.profile
list
- (<c>.run /.project)
+ (<code>.run /.project)
(case> (#try.Success actual)
(|> expected
..with_default_sources
+ ..with_default_repository
(//project.project //.default)
(\ //project.equivalence = actual))
@@ -93,13 +98,15 @@
(|> expected
//format.project
list
- (<c>.run /.project)
+ (<code>.run /.project)
(case> (#try.Success actual)
(|> expected
..with_empty_profile
dictionary.entries
(list\map (function (_ [name profile])
- [name (..with_default_sources profile)]))
+ [name (|> profile
+ ..with_default_sources
+ ..with_default_repository)]))
(dictionary.from_list text.hash)
(\ //project.equivalence = actual))
diff --git a/stdlib/source/test/aedifex/pom.lux b/stdlib/source/test/aedifex/pom.lux
index c87ff0590..75b8cf5dc 100644
--- a/stdlib/source/test/aedifex/pom.lux
+++ b/stdlib/source/test/aedifex/pom.lux
@@ -30,11 +30,12 @@
(get@ #//.identity expected)]
[(#try.Success pom)
(#.Some _)]
- (case (<xml>.run /.parser pom)
+ (case (<xml>.run /.parser (list pom))
(#try.Success actual)
(\ //.equivalence =
(|> (\ //.monoid identity)
- (set@ #//.dependencies (get@ #//.dependencies expected)))
+ (set@ #//.dependencies (get@ #//.dependencies expected))
+ (set@ #//.repositories (get@ #//.repositories expected)))
actual)
(#try.Failure error)