diff options
Diffstat (limited to 'stdlib/test/test/lux/control/reader.lux')
-rw-r--r-- | stdlib/test/test/lux/control/reader.lux | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/stdlib/test/test/lux/control/reader.lux b/stdlib/test/test/lux/control/reader.lux index 57f487426..638e11519 100644 --- a/stdlib/test/test/lux/control/reader.lux +++ b/stdlib/test/test/lux/control/reader.lux @@ -8,25 +8,25 @@ lux/test) (context: "Readers" - (let [(^open "&/.") &.Apply<Reader> - (^open "&/.") &.Monad<Reader>] + (let [(^open "&/.") &.apply + (^open "&/.") &.monad] ($_ seq (test "" (i/= +123 (&.run +123 &.ask))) (test "" (i/= +246 (&.run +123 (&.local (i/* +2) &.ask)))) (test "" (i/= +134 (&.run +123 (&/map inc (i/+ +10))))) (test "" (i/= +10 (&.run +123 (&/wrap +10)))) (test "" (i/= +30 (&.run +123 (&/apply (&/wrap (i/+ +10)) (&/wrap +20))))) - (test "" (i/= +30 (&.run +123 (do &.Monad<Reader> + (test "" (i/= +30 (&.run +123 (do &.monad [f (wrap i/+) x (wrap +10) y (wrap +20)] (wrap (f x y))))))))) (context: "Monad transformer" - (let [(^open "io/.") io.Monad<IO>] + (let [(^open "io/.") io.monad] (test "Can add reader functionality to any monad." (|> (: (&.Reader Text (io.IO Int)) - (do (&.ReaderT io.Monad<IO>) + (do (&.ReaderT io.monad) [a (&.lift (io/wrap +123)) b (wrap +456)] (wrap (i/+ a b)))) |