File tree 2 files changed +4
-2
lines changed
src/lambdaisland/deep_diff2
test/lambdaisland/deep_diff2
2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change 107
107
(fn [[m idx] k]
108
108
[(cond-> m
109
109
(contains? del idx)
110
- (assoc (->Deletion k) (exp k))
110
+ (assoc (->Deletion k) (get exp k))
111
111
112
112
(not (contains? del idx))
113
113
(assoc k (diff (get exp k) (get act k)))
Original file line number Diff line number Diff line change 96
96
(is (= {:a (diff/->Mismatch 1 2 )}
97
97
(diff/diff (map->ARecord {:a 1 }) (map->ARecord {:a 2 }))))
98
98
(is (= {(diff/->Insertion :a ) 1 }
99
- (diff/diff (map->ARecord {}) (map->ARecord {:a 1 }))))))
99
+ (diff/diff (map->ARecord {}) (map->ARecord {:a 1 }))))
100
+ (is (= {(diff/->Deletion :a ) 1 }
101
+ (diff/diff (map->ARecord {:a 1 }) (map->ARecord {}))))))
100
102
101
103
(is (= [{:x (diff/->Mismatch 1 2 )}]
102
104
(diff/diff [{:x 1 }] [{:x 2 }])))
You can’t perform that action at this time.
0 commit comments