bensu / doo

doo is a library and lein plugin to run cljs.test on different js environments.
Eclipse Public License 1.0
324 stars 63 forks source link

Cannot require macros from test directory? #52

Closed exupero closed 8 years ago

exupero commented 8 years ago

I have a then.clj file in the test/project directory (as opposed to src/project), but when I require it I get

java.io.FileNotFoundException: Could not locate project/then__init.class or project/then.clj on classpath.

I know the test directory is getting included in the build because it finds the .cljs files. Is there something special I need to do to get .clj files outside src to be found by the ClojureScript compiler?

danielcompton commented 8 years ago

Does this work in cljsbuild? Can you post your project.clj?

exupero commented 8 years ago

Turns out the problem was that I didn't have a top-level :source-paths set in my project.clj. Adding :source-paths ["src" "test"] solved the problem.