File tree Expand file tree Collapse file tree 2 files changed +14
-5
lines changed
src/clojure/tools/namespace
test/clojure/tools/namespace Expand file tree Collapse file tree 2 files changed +14
-5
lines changed Original file line number Diff line number Diff line change 111
111
(def ^:private ns-clause-head-names
112
112
" Set of symbol/keyword names which can appear as the head of a
113
113
clause in the ns form."
114
- #{" use" " require" })
114
+ #{" use" " require" " require-macros " })
115
115
116
116
(def ^:private ns-clause-heads
117
117
" Set of all symbols and keywords which can appear at the head of a
Original file line number Diff line number Diff line change 184
184
deps-from-ns-decl)]
185
185
(is (= #{'clojure.string} actual)))))
186
186
187
-
188
- (def ns-with-npm-dependency
187
+ (def cljs-ns-with-npm-dependency
189
188
" (ns com.examples.one
190
189
(:require [\" foobar\" ] [baz]))" )
191
190
192
191
(deftest cljs-string-dependency
193
- (let [actual (-> ns-with-npm-dependency
192
+ (let [actual (-> cljs-ns-with-npm-dependency
193
+ str->ns-decl
194
+ deps-from-ns-decl)]
195
+ (is (= #{'baz} actual))))
196
+
197
+ (def cljs-ns-with-require-macros
198
+ " (ns com.examples.one
199
+ (:require-macros [org.macros :refer [my-macro]]))" )
200
+
201
+ (deftest cljs-require-macros
202
+ (let [actual (-> cljs-ns-with-require-macros
194
203
str->ns-decl
195
204
deps-from-ns-decl)]
196
- (is (= #{'baz } actual))))
205
+ (is (= #{'org.macros } actual))))
You can’t perform that action at this time.
0 commit comments