Skip to content
Browse files

test for #361: merge-with for defrecord

Signed-off-by: Stuart Halloway <stu@thinkrelevance.com>
  • Loading branch information...
1 parent 673f4c7 commit 3353eeafb5aab2e465fb953f3f50ac7bc60c2e0a @stuarthalloway stuarthalloway committed
Showing with 2 additions and 1 deletion.
  1. +2 −1 test/clojure/test_clojure/protocols.clj
View
3 test/clojure/test_clojure/protocols.clj
@@ -187,7 +187,8 @@
(deftest defrecord-acts-like-a-map
(let [rec (r 1 2)]
- (is (= (r 1 3 {} {:c 4}) (merge rec {:b 3 :c 4})))))
+ (is (= (r 1 3 {} {:c 4}) (merge rec {:b 3 :c 4})))
+ (is (= {:a 11 :b 2 :c 10} (merge-with + rec {:a 10 :c 10})))))
(deftest defrecord-interfaces-test
(testing "java.util.Map"

0 comments on commit 3353eea

Please sign in to comment.
Something went wrong with that request. Please try again.