diff --git a/test-namespaces/good_conditionals/conditional_with_require_macros.cljc b/test-namespaces/good_conditionals/conditional_with_require_macros.cljc new file mode 100644 index 0000000..8d28843 --- /dev/null +++ b/test-namespaces/good_conditionals/conditional_with_require_macros.cljc @@ -0,0 +1,11 @@ +(ns good-conditionals.conditional-with-require-macros + (:require [clojure.string :as str]) + #?(:cljs (:require-macros [good-conditionals.conditional-with-require-macros :refer [my-when]]))) + +#?(:clj + (defmacro my-when [x] + `(when true + ~x))) + +(defn hello [] + (my-when (println (str/join) "H" "ello"))) diff --git a/test/check_namespace_decls/core_test.clj b/test/check_namespace_decls/core_test.clj index d4e7010..5ac305c 100644 --- a/test/check_namespace_decls/core_test.clj +++ b/test/check_namespace_decls/core_test.clj @@ -50,7 +50,7 @@ (deftest good-conditionals (with-project [project ["good_conditionals" {:prefix-rewriting false}]] (is (nil? (check-decls project))) - (is (= ["Checked 1 files; 0 had errors."] + (is (= ["Checked 2 files; 0 had errors."] (capture-output #(check-decls project)))))) (deftest good-prefixes