diff options
Diffstat (limited to 'lib/contains.test.fnl')
-rw-r--r-- | lib/contains.test.fnl | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/contains.test.fnl b/lib/contains.test.fnl new file mode 100644 index 0000000..1c7fb06 --- /dev/null +++ b/lib/contains.test.fnl @@ -0,0 +1,11 @@ +(let [{: contains } (require :lib.contains)] + (let [given "a list and an element it contains" + should "returns true" + expected true + actual (contains [:apple :orange :pear] :apple)] + (assert (= actual expected) (.. "Given " given " should " should))) + (let [given "a list and an element it does not contain" + should "returns false" + expected false + actual (contains [:apple :orange :pear] :gorilla)] + (assert (= actual expected) (.. "Given " given " should " should)))) |