diff options
| author | Asko Nõmm <asko@nmm.ee> | 2025-10-20 00:46:16 +0300 |
|---|---|---|
| committer | Asko Nõmm <asko@nmm.ee> | 2025-10-20 00:46:16 +0300 |
| commit | 325f4300292b8895838b1b8e3fd2b8dd735d311f (patch) | |
| tree | a1589f802b136f83fe93f161c16f8bf59eeb72ac /test/dompa | |
| parent | 7644be5e3beff7ee986aa77dc47e27aac0f22e1f (diff) | |
#7: Have the round trip test run only in server-side (cljs has no slurp)
Diffstat (limited to 'test/dompa')
| -rw-r--r-- | test/dompa/round_trip_test.clj | 11 | ||||
| -rw-r--r-- | test/dompa/round_trip_test.cljc | 14 |
2 files changed, 11 insertions, 14 deletions
diff --git a/test/dompa/round_trip_test.clj b/test/dompa/round_trip_test.clj new file mode 100644 index 0000000..0e5d1fa --- /dev/null +++ b/test/dompa/round_trip_test.clj @@ -0,0 +1,11 @@ +(ns dompa.round-trip-test + (:require [clojure.test :refer [deftest is testing]] + [dompa.nodes :as nodes] + [dompa.html :as html])) + +(deftest round-trip-test + (testing "michiel borkent website" + (let [input-html (slurp "test/dompa/html/michiel_borkent.html") + nodes (html/->nodes input-html) + output-html (nodes/->html nodes)] + (is (= input-html output-html)))))
\ No newline at end of file diff --git a/test/dompa/round_trip_test.cljc b/test/dompa/round_trip_test.cljc deleted file mode 100644 index 9413988..0000000 --- a/test/dompa/round_trip_test.cljc +++ /dev/null @@ -1,14 +0,0 @@ -(ns dompa.round-trip-test - #?(:clj (:require [clojure.test :refer [deftest is testing]] - [dompa.nodes :as nodes] - [dompa.html :as html])) - #?(:cljs (:require [cljs.test :refer-macros [deftest testing is]] - [dompa.nodes :as nodes] - [dompa.html :as html]))) - -(deftest round-trip-test - (testing "michiel borkent website" - (let [input-html (slurp "test/dompa/html/michiel_borkent.html") - nodes (html/->nodes input-html) - output-html (nodes/->html nodes)] - (is (= input-html output-html)))))
\ No newline at end of file |
