Last active
February 4, 2017 22:04
-
-
Save swlkr/0f747af124fa7a6c29581c0bc4ac420a to your computer and use it in GitHub Desktop.
create-record-test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns proj.records-test | |
(:require [proj.records :refer :all] | |
[clojure.test :refer :all])) | |
(deftest create-record-test | |
(with-redefs [db/insert-record<! (fn [arg] (assoc arg :id 1))] | |
(testing "with valid record data" | |
(let [arg {:content "hello world"}] | |
(is (= {:id 1 :content "hello world"} (create! arg))))))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment