Closed zakak closed 7 years ago
Hello and thanks for all your open source work, including duct.
I noticed lein new duct demo +ataraxy +example creates tests that fail, though http://localhost/example loads fine in the browser.
lein new duct demo +ataraxy +example
http://localhost/example
The kerodon (status? 200) test is looking for [:response :status]:
(status? 200)
[:response :status]
;; with +ataraxy +example (deftest smoke-test (testing "example page exists" (-> (session handler) (visit "/example") ;; {:response [:ataraxy.response/ok "This is an example handler"] ...} (has (status? 200) "page exists")))) ;; fails
;; with +example (deftest smoke-test (testing "example page exists" (-> (session handler) (visit "/example") ;; {:response {:status 200, :headers {"Content-Type" "text/html; charset=utf-8"}, :body "This is an example handler"} (has (status? 200) "page exists")))) ;; passes
Thanks for opening the issue. Just wanted to say that I have actually noticed this, and that I'm thinking about how best to solve it.
Should be fixed in 0.10.4.
Works for me now, thanks!
Hello and thanks for all your open source work, including duct.
I noticed
lein new duct demo +ataraxy +example
creates tests that fail, thoughhttp://localhost/example
loads fine in the browser.The kerodon
(status? 200)
test is looking for[:response :status]
: