Skip to content

Commit

Permalink
fixup! Add return type tests for combine
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyheiler committed Jan 5, 2019
1 parent 8d28e41 commit b14f3ea
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions test/test_util.clj
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,13 @@
(facts "combine function"
(facts "simple combinations"
(fact "merges map" (combine {:a 1} {:b 2}) => {:a 1 :b 2})
(fact "returns a map" (combine {:a 1} {:b 2}) => map?)
(fact "concats list" (combine '(1 2) [3 4]) => '(1 2 3 4))
(fact "returns a list" (combine '(1 2) [3 4]) => list?)
(fact "concats vector" (combine [1 2] '(3 4)) => [1 2 3 4])
(fact "returns a vector" (combine [1 2] '(3 4)) => vector?)
(fact "concats set" (combine #{1 2} [3 4]) => #{1 2 3 4})
(fact "returns a set" (combine #{1 2} [3 4]) => set?)
(facts "replaces other types"
(fact (combine 123 456) => 456)
(fact (combine "abc" 123) => 123)
Expand Down

0 comments on commit b14f3ea

Please sign in to comment.