Skip to content

Redo test build when src has changed? #159

bsteuber opened this Issue Dec 1, 2012 · 2 comments

2 participants

bsteuber commented Dec 1, 2012

I am trying to have cljsbuild auto recompile my unit tests (built from test-cljs) every time a file in my cljs-src dir has changed. This would be very useful for my setup with guard-livereload and jasmine - basically each time I save a file my unit test results are automatically refreshed in the browser.
However, with the current behavior of cljsbuild, I have to touch a test file before my changes in cljs-src become visible.

Of course, this would be fixed by Issue 108, but until multiple source paths are allowed in the cljs compiler, I'd propose a per-build option like :watch-dirs ["cljs-src"] to achieve this effect.

I could try implementing this myself (and probably will), but before starting I want make sure I didn't overlook another way to achieve the desired behavior.

emezeske commented Dec 2, 2012

Is this a duplicate of Issue #140?

I don't think there's any way to do this right now. I would gladly accept a clean patch that made it happen.

bsteuber commented Dec 2, 2012

Okay, hadn't seen the other one - well this seems more tricky than I thought.
But since I am using some Ruby tools anyways, I have found another workaround, namely configuring guard-shell to touch one of the test files whenever my main.js has changed. Pretty dirty, but does the job for me xD

@bsteuber bsteuber closed this Dec 2, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.