Created
January 6, 2015 12:56
-
-
Save martinklepsch/dbcc7702b36b7e879419 to your computer and use it in GitHub Desktop.
This file contains 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
(deftest notification-unsuccessful | |
(testing "Notification check-fn not fulfilled" | |
(let [requests (atom [])] | |
(reset! requests []) | |
(with-fake-http [test-uri (fn [orig-fn opts callback] | |
(swap! requests conj (:url opts)) | |
{:status 200 :body "ok"})] | |
(n/notify test-uri #(= % "bla") :wait-times [1 2 3 4]) | |
(Thread/sleep 100) ; Urgs | |
(is (= 5 (count @requests))))))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment