mirror of https://github.com/status-im/reagent.git
Make browser tests clean up after themselves properly
This commit is contained in:
parent
e193518292
commit
0215a4a093
|
@ -26,7 +26,8 @@
|
|||
(let [div (add-test-div "_testreagent")]
|
||||
(let [comp (reagent/render-component comp div #(f comp div))]
|
||||
(reagent/unmount-component-at-node div)
|
||||
(reagent/flush)))))
|
||||
(reagent/flush)
|
||||
(.removeChild (.-body js/document) div)))))
|
||||
|
||||
(defn found-in [re div]
|
||||
(let [res (.-innerHTML div)]
|
||||
|
|
|
@ -15,7 +15,8 @@
|
|||
(let [div (add-test-div "_testreagent")]
|
||||
(let [comp (r/render-component comp div #(f comp div))]
|
||||
(r/unmount-component-at-node div)
|
||||
(r/flush)))))
|
||||
(r/flush)
|
||||
(.removeChild (.-body js/document) div)))))
|
||||
|
||||
(defn found-in [re div]
|
||||
(let [res (.-innerHTML div)]
|
||||
|
|
Loading…
Reference in New Issue