rtfeldman/node-test-runner

Deduplicate src-dirs

Opened this issue · 2 comments

I'd really like to deduplicate the test folders when they're exact matches; I have a project where I want to add the tests folder as an app src dir.

.concat(shouldAddTestsDirAsSource ? [testsDir] : []);

I'm getting this error if I add the tests folder to src-dirs:


/Users/drathier/drathier/elm-everything/tests/BasicsTests.elm

…matches more than one source directory:

/Users/drathier/drathier/elm-everything/tests
/Users/drathier/drathier/elm-everything/tests

Edit "source-directories" in your elm.json and try to make it so no source directory contains another source directory!

Note: The tests/ folder counts as a source directory too (even if it isn't listed in your elm.json)!```

I think it makes sense to not add the tests/ dir if it’s already in source-directories!

(Not sure about de-duplicating, though, I think it would make the most sense if elm-test and elm make gave the same error, instead of elm-test working while plain elm does not.)