mirror of https://github.com/status-im/reagent.git
Fix doo & test result component on demo app
This commit is contained in:
parent
f590c342eb
commit
b81af9308a
|
@ -6,7 +6,8 @@
|
|||
[reagentdemo.intro :as intro]
|
||||
[reagentdemo.news :as news]
|
||||
[reagenttest.runtests :as tests]
|
||||
[reagent.debug :refer-macros [dbg println]]))
|
||||
[reagent.debug :refer-macros [dbg println]]
|
||||
[doo.runner :as doo]))
|
||||
|
||||
(def github {:href "https://github.com/reagent-project/reagent"})
|
||||
|
||||
|
@ -31,11 +32,12 @@
|
|||
[:li [link {:href news/url} "News"]]
|
||||
[:li>a github "GitHub"]
|
||||
[:li [:a {:href "http://reagent-project.github.io/docs/master/"} "API"]]]
|
||||
[:div @tests/test-results]
|
||||
[:div @tests/test-results-component]
|
||||
[tools/main-content]
|
||||
[github-badge]])
|
||||
|
||||
(defn init! []
|
||||
(doo/set-exit-point! (fn [success?] nil))
|
||||
(tests/init!)
|
||||
(tools/start! {:body [#'demo]
|
||||
:title-prefix "Reagent: "
|
||||
|
|
|
@ -49,10 +49,12 @@
|
|||
(:fail res) " failures, " (:error res) " errors."])
|
||||
"testing")]))
|
||||
|
||||
(def test-results-component (r/atom nil))
|
||||
|
||||
(defn init! []
|
||||
(when (some? (test/deftest empty-test))
|
||||
;; Only run with :load-tests true
|
||||
(reset! test-results [#'test-output-mini])
|
||||
(reset! test-results-component [#'test-output-mini])
|
||||
(run-tests)))
|
||||
|
||||
(doo-tests 'reagenttest.testreagent
|
||||
|
|
Loading…
Reference in New Issue