diff options
Diffstat (limited to 'stdlib/source/test/lux/control/parser/synthesis.lux')
-rw-r--r-- | stdlib/source/test/lux/control/parser/synthesis.lux | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/stdlib/source/test/lux/control/parser/synthesis.lux b/stdlib/source/test/lux/control/parser/synthesis.lux index 8e974ad33..7046d5d1d 100644 --- a/stdlib/source/test/lux/control/parser/synthesis.lux +++ b/stdlib/source/test/lux/control/parser/synthesis.lux @@ -55,9 +55,9 @@ (def: random_environment (Random (Environment Synthesis)) (do [! random.monad] - [size (# ! each (n.% 5) random.nat)] + [size (at ! each (n.% 5) random.nat)] (|> ..random_variable - (# ! each (|>> synthesis.variable)) + (at ! each (|>> synthesis.variable)) (random.list size)))) (def: simple @@ -66,12 +66,12 @@ (~~ (template [<query> <check> <random> <synthesis> <equivalence>] [(do [! random.monad] [expected <random> - dummy (|> <random> (random.only (|>> (# <equivalence> = expected) not)))] + dummy (|> <random> (random.only (|>> (at <equivalence> = expected) not)))] (all _.and (_.coverage [<query>] (|> (/.result <query> (list (<synthesis> expected))) (!expect (^.multi {try.#Success actual} - (# <equivalence> = expected actual))))) + (at <equivalence> = expected actual))))) (_.coverage [<check>] (and (|> (/.result (<check> expected) (list (<synthesis> expected))) (!expect {try.#Success _})) @@ -105,10 +105,10 @@ (synthesis.f64 expected_f64) (synthesis.text expected_text))))) (!expect (^.multi {try.#Success [actual_bit actual_i64 actual_f64 actual_text]} - (and (# bit.equivalence = expected_bit actual_bit) - (# i64.equivalence = expected_i64 actual_i64) - (# frac.equivalence = expected_f64 actual_f64) - (# text.equivalence = expected_text actual_text))))) + (and (at bit.equivalence = expected_bit actual_bit) + (at i64.equivalence = expected_i64 actual_i64) + (at frac.equivalence = expected_f64 actual_f64) + (at text.equivalence = expected_text actual_text))))) (|> (/.result (/.tuple (all <>.and /.bit /.i64 /.f64 /.text)) (list (synthesis.text expected_text))) (!expect (^.multi {try.#Failure error} @@ -121,10 +121,10 @@ (and (|> (/.result (/.function arity /.text) (list (synthesis.function/abstraction [expected_environment arity (synthesis.text expected_body)]))) (!expect (^.multi {try.#Success [actual_environment actual_body]} - (and (# (list.equivalence synthesis.equivalence) = - expected_environment - actual_environment) - (# text.equivalence = expected_body actual_body))))) + (and (at (list.equivalence synthesis.equivalence) = + expected_environment + actual_environment) + (at text.equivalence = expected_body actual_body))))) (|> (/.result (/.function arity /.text) (list (synthesis.text expected_body))) (!expect (^.multi {try.#Failure error} @@ -139,7 +139,7 @@ (!expect (^.multi {try.#Failure error} (exception.match? /.wrong_arity error)))))) (do [! random.monad] - [arity (# ! each (|>> (n.% 10) ++) random.nat) + [arity (at ! each (|>> (n.% 10) ++) random.nat) expected_offset random.nat expected_inits (random.list arity random.bit) expected_body (random.unicode 1)] @@ -149,11 +149,11 @@ (list#each (|>> synthesis.bit) expected_inits) (synthesis.text expected_body)]))) (!expect (^.multi {try.#Success [actual_offset actual_inits actual_body]} - (and (# n.equivalence = expected_offset actual_offset) - (# (list.equivalence bit.equivalence) = - expected_inits - actual_inits) - (# text.equivalence = expected_body actual_body))))) + (and (at n.equivalence = expected_offset actual_offset) + (at (list.equivalence bit.equivalence) = + expected_inits + actual_inits) + (at text.equivalence = expected_body actual_body))))) (|> (/.result (/.loop (<>.many /.bit) /.text) (list (synthesis.text expected_body))) (!expect (^.multi {try.#Failure error} @@ -166,23 +166,23 @@ (_.for [/.Parser]) (all _.and (do [! random.monad] - [expected (# ! each (|>> synthesis.i64) random.i64)] + [expected (at ! each (|>> synthesis.i64) random.i64)] (_.coverage [/.result /.any] (|> (/.result /.any (list expected)) (!expect (^.multi {try.#Success actual} - (# synthesis.equivalence = expected actual)))))) + (at synthesis.equivalence = expected actual)))))) (_.coverage [/.empty_input] (|> (/.result /.any (list)) (!expect (^.multi {try.#Failure error} (exception.match? /.empty_input error))))) (do [! random.monad] - [expected (# ! each (|>> synthesis.i64) random.i64)] + [expected (at ! each (|>> synthesis.i64) random.i64)] (_.coverage [/.unconsumed_input] (|> (/.result /.any (list expected expected)) (!expect (^.multi {try.#Failure error} (exception.match? /.unconsumed_input error)))))) (do [! random.monad] - [dummy (# ! each (|>> synthesis.i64) random.i64)] + [dummy (at ! each (|>> synthesis.i64) random.i64)] (_.coverage [/.end /.expected_empty_input] (and (|> (/.result /.end (list)) (!expect {try.#Success _})) @@ -190,7 +190,7 @@ (!expect (^.multi {try.#Failure error} (exception.match? /.expected_empty_input error))))))) (do [! random.monad] - [dummy (# ! each (|>> synthesis.i64) random.i64)] + [dummy (at ! each (|>> synthesis.i64) random.i64)] (_.coverage [/.end?] (and (|> (/.result /.end? (list)) (!expect {try.#Success #1})) |