瀏覽代碼

fix: new graph-parser test passes with clj runner

part of LOG-3092
Gabriel Horner 1 年之前
父節點
當前提交
b70ba087b3

+ 1 - 0
deps/graph-parser/deps.edn

@@ -7,6 +7,7 @@
   logseq/db                   {:local/root "../db"}
   logseq/common               {:local/root "../common"}
   ;; stubbed in nbb
+  funcool/promesa             {:mvn/version "4.0.2"}
   com.lambdaisland/glogi      {:mvn/version "1.1.144"}
   ;; built in to nbb
   cljs-bean/cljs-bean         {:mvn/version "1.5.0"}}

+ 2 - 3
deps/graph-parser/test/logseq/graph_parser/exporter_test.cljs

@@ -1,11 +1,10 @@
-(ns logseq.graph-parser.exporter-test
+(ns ^:node-only logseq.graph-parser.exporter-test
   (:require [cljs.test :refer [testing is]]
             [logseq.graph-parser.test.helper :as test-helper :include-macros true :refer [deftest-async]]
             [datascript.core :as d]
             [clojure.string :as string]
             ["path" :as node-path]
             ["fs" :as fs]
-            ["fs/promises" :as fsp]
             [logseq.common.graph :as common-graph]
             [promesa.core :as p]
             [logseq.db.frontend.schema :as db-schema]
@@ -27,7 +26,7 @@
 
 (defn- <read-file
   [file]
-  (p/let [s (fsp/readFile (:path file))]
+  (p/let [s (fs/readFileSync (:path file))]
     (str s)))
 
 (defn- notify-user [m]

+ 0 - 0
deps/graph-parser/test/logseq/graph_parser/test/helper.clj → deps/graph-parser/test/logseq/graph_parser/test/helper.cljc