;; Copyright (C) 2023 Felisp ;; ;; This program is free software: you can redistribute it and/or modify ;; it under the terms of the GNU Affero General Public License as published by ;; the Free Software Foundation, version 3 of the License. ;; ;; This program is distributed in the hope that it will be useful, ;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;; GNU Affero General Public License for more details. ;; ;; You should have received a copy of the GNU Affero General Public License ;; along with this program. If not, see . (ns rss-thread-watch.utils-test (:require [clojure.test :refer :all] [rss-thread-watch.utils :refer :all])) (def first-map {:a :b :c "c"}) (def empty-map {}) (deftest map-deep-merge-missing-test (testing "Default values in place of missing keys" (is (= first-map (map-apply-defaults first-map empty-map)) "No defaults should return conf map unchanged") (is (= first-map (map-apply-defaults empty-map first-map)) "Empty map should be completely replaced by defaults")))