From a6a17f1234d9110cac6ada5bfbdd7460c262c8a8 Mon Sep 17 00:00:00 2001 From: lread Date: Sun, 8 Sep 2024 14:41:27 -0400 Subject: [PATCH] lib test: patch zprint to disable new failing test See https://github.com/kkinnear/zprint/issues/333 --- script/test_libs.clj | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/script/test_libs.clj b/script/test_libs.clj index cab5066..16e53b6 100755 --- a/script/test_libs.clj +++ b/script/test_libs.clj @@ -245,7 +245,16 @@ (string/replace #"\[lein-zprint \"1.2.4\"\]" "[lein-zprint \"1.2.4.1\"]") (->> (spit p)))) - (show-patch-diff lib)) + ;; zprint 1.2.9 has a single failing test for https://github.com/clj-commons/rewrite-clj/pull/306 + ;; Have raised this with over at zprint https://github.com/kkinnear/zprint/issues/333 + ;; and have agreement that it is a zprint issue. + ;; Disable the failing test which starts on line 2538 + (status/line :detail "Patching for failing test in v1.2.9") + (let [p (str (fs/file home-dir "test/zprint/guide_test.cljc")) + lines (-> p slurp string/split-lines) + new-lines (update lines 2537 #(str "#_" %))] + (->> (string/join "\n" new-lines) + (spit p)))) (defn- zprint-prep [{:keys [home-dir]}] (status/line :detail "=> Building uberjar for uberjar tests") @@ -449,7 +458,7 @@ :test-cmds ["lein test"]} {:name "zprint" :version "1.2.9" - :note "1) planck cljs tests disabled for now: https://github.com/planck-repl/planck/issues/1088" + :note "1) planck cljs tests disabled for now: https://github.com/planck-repl/planck/issues/1088 2) failing v1.2.9 test disabled" :platforms [:clj :cljs] :github-release {:repo "kkinnear/zprint"} :patch-fn zprint-patch