diff options
Diffstat (limited to 'stdlib/test/test/lux/data/struct/zipper.lux')
-rw-r--r-- | stdlib/test/test/lux/data/struct/zipper.lux | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/stdlib/test/test/lux/data/struct/zipper.lux b/stdlib/test/test/lux/data/struct/zipper.lux index a1045f44f..8e45b4ef1 100644 --- a/stdlib/test/test/lux/data/struct/zipper.lux +++ b/stdlib/test/test/lux/data/struct/zipper.lux @@ -56,8 +56,8 @@ (let [child (|> zipper &;down)] (and (not (Tree/= sample (&;to-tree child))) (|> child &;parent (default (undefined)) (is zipper)) - (|> child &;up (is zipper)) - (|> child &;root (is zipper)))) + (|> child &;up (is zipper) not) + (|> child &;root (is zipper) not))) (and (&;leaf? zipper) (|> zipper (&;prepend-child new-val) &;branch?))))) @@ -72,7 +72,7 @@ (|> zipper &;down &;right &;value (is mid-val)) (|> zipper &;down &;right &;right &;value (is post-val)) (|> zipper &;down &;rightmost &;leftmost &;value (is pre-val)) - (|> zipper &;down &;right &;left &;value (is mid-val)) + (|> zipper &;down &;right &;left &;value (is pre-val)) (|> zipper &;down &;rightmost &;value (is post-val)))) true))) @@ -91,7 +91,7 @@ (|> zipper &;down &;right &;value (is mid-val)) (|> zipper &;down &;right &;right &;value (is post-val)) (|> zipper &;down &;rightmost &;leftmost &;value (is pre-val)) - (|> zipper &;down &;right &;left &;value (is mid-val)) + (|> zipper &;down &;right &;left &;value (is pre-val)) (|> zipper &;down &;rightmost &;value (is post-val)))) (and (|> zipper (&;insert-left pre-val) (case> (#;Some _) false #;None true)) @@ -105,7 +105,7 @@ (List/= (tree;flatten sample) (loop [zipper (&;from-tree sample)] (if (&;end? zipper) - (list) + (list (&;value zipper)) (#;Cons (&;value zipper) (recur (&;next zipper))))))) @@ -113,7 +113,7 @@ (List/= (list;reverse (tree;flatten sample)) (loop [zipper (to-end (&;from-tree sample))] (if (&;root? zipper) - (list) + (list (&;value zipper)) (#;Cons (&;value zipper) (recur (&;prev zipper))))))) |