Fork me on GitHub

I’m trying to mark my test folder as Test Root, but it keeps getting unmarked when I re-open the project. I’m using a maven style project layout. As you can see, the src/test/clojure folder is not a test root which makes me unable to call Load file in REPL from my tests.


I had something like that once and I’m trying to remember the cause — I think it was the way I had source paths set up in my project.clj file?


I’m using deps.edn. The test path is added in a :unit-test alias. Maybe the alias must start with test or something


That’s actually it. Only if the alias is exactly equal to :test will it mark the added paths as test roots


Curious if anyone else is seeing this issue with jumping b/w test and impl?


@dmarjenburgh Yes, sadly deps doesn’t distinguish between source and test roots, so the only way to identify them is based on the alias name. I could probably do something like “Any alias containing ‘test[s]?’ as one of its segments” (like your :unit-test).


would that be possible to retain manual directory markings between deps imports? that way the only heuristic would be to look for test[s] alias, but users can correct the initial import's decision manually with the mark directory as... action and subsequent imports should "just" honor those decisions.


I actually don’t necessarily expect Cursive to know my test dirs. I guess applying a one-off heuristic is fine, but after that I’m ok with manually assigning test roots, as long is it isn’t removed afterwards.


@sooheon.k No-one else has reported that, I’ll try to reproduce it next week.