aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/test/aedifex
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/source/test/aedifex')
-rw-r--r--stdlib/source/test/aedifex/parser.lux15
-rw-r--r--stdlib/source/test/aedifex/pom.lux5
2 files changed, 14 insertions, 6 deletions
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)