aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/library
diff options
context:
space:
mode:
authorEduardo Julian2022-04-09 03:03:46 -0400
committerEduardo Julian2022-04-09 03:03:46 -0400
commit04c7f49a732380a2b9f72b1b937171b341c24323 (patch)
treed54c92bf10665bba0ec4643746becce569604fb2 /stdlib/source/library
parentf11afb9d2dfe2d59b41e8056eb8c4ae65268415f (diff)
Better names for testing macros (plus better indentation).
Diffstat (limited to 'stdlib/source/library')
-rw-r--r--stdlib/source/library/lux/test.lux16
1 files changed, 8 insertions, 8 deletions
diff --git a/stdlib/source/library/lux/test.lux b/stdlib/source/library/lux/test.lux
index 9a42e0735..ac03309eb 100644
--- a/stdlib/source/library/lux/test.lux
+++ b/stdlib/source/library/lux/test.lux
@@ -133,7 +133,7 @@
[..success_tally (format ..success_prefix message)]
[..failure_tally (format ..failure_prefix message)])))
-(def: .public (test message condition)
+(def: .public (property message condition)
(-> Text Bit Test)
(random#in (..assertion (%.text message) condition)))
@@ -272,7 +272,7 @@
(%.Format Symbol)
(|>> %.symbol (format ..clean_up_marker)))
-(def: (|cover'| coverage condition)
+(def: (|coverage'| coverage condition)
(-> (List Symbol) Bit Assertion)
(let [message (|> coverage
(list#each ..coverage_format)
@@ -283,9 +283,9 @@
[(revised #actual_coverage (set.union coverage) tally)
documentation])))))
-(def: (|cover| coverage condition)
+(def: (|coverage| coverage condition)
(-> (List Symbol) Bit Test)
- (|> (..|cover'| coverage condition)
+ (|> (..|coverage'| coverage condition)
random#in))
(def: (|for| coverage test)
@@ -321,7 +321,7 @@
_ (format aggregate ..coverage_separator short)))
""))
-(def: (coverage module encoding)
+(def: (coverage_definitions module encoding)
(-> Text Text (Set Symbol))
(loop (again [remaining encoding
output (set.of_list symbol.hash (list))])
@@ -343,8 +343,8 @@
(.list (~+ coverage)))
(~ condition)))))))]
- [cover' ..|cover'|]
- [cover ..|cover|]
+ [coverage' ..|coverage'|]
+ [coverage ..|coverage|]
)
(syntax: .public (for [coverage (<code>.tuple (<>.many <code>.any))
@@ -359,7 +359,7 @@
(def: (covering' module coverage test)
(-> Text Text Test Test)
- (let [coverage (..coverage module coverage)]
+ (let [coverage (..coverage_definitions module coverage)]
(|> (..context' module test)
(random#each (async#each (function (_ [tally documentation])
[(revised #expected_coverage (set.union coverage) tally)