lambdaisland / kaocha-cljs

ClojureScript support for Kaocha
Eclipse Public License 1.0
40 stars 10 forks source link

Dynamic classpath handling does not work #5

Closed plexus closed 1 year ago

plexus commented 5 years ago

Kaocha adds any :test-paths to the classpath, so you don't have to, and so that only suites that are being run get added. However ClojureScript does not seem to pick up on this, so you need to add your test directories to the classpath yourself (e.g. in tools.deps with :paths or leiningen :test-paths).

Would be good to figure out what ClojureScript needs to make this work.

plexus commented 5 years ago

Related: #4

urzae commented 5 years ago

/cc @urzds

ghost commented 5 years ago

@plexus: We ran into this issue when taking our first steps at writing tests for our UI. Would it be possible to document this behaviour? Especially since this is not necessary for Clojure tests it took us a while to figure out what is wrong.

plexus commented 5 years ago

Sure, a PR for the README would be most welcome!

fdserr commented 1 year ago

@plexus Isn't the readme already up to date on this issue?

[...]
## Known issues
- The :test-paths do not get automatically added to the classpath (at least not in a way that makes the sources visible to ClojureScript), so you need to also have any :test-paths in your project.clj/deps.edn/build.boot.
[...]
plexus commented 1 year ago

Right, makes sense that this was already documented. The original ticket was about figuring out if we can make it work on ClojureScript too. This could in theory still be investigated, but it's not something I want us to spend time on. Why? Because hacking the classpath like this is always hacky, and easily introduces new issues, or lead to suprising behavior. Let the tools that are designed to manage the classpath manage the classpath.

I think we have many other things to spend our time on that will have a greater positive impact for users.

So, until further notice I'm going to close this as "wontfix".