Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Public interface for clearing speclj state #139

Open
awkay opened this issue Aug 12, 2015 · 1 comment
Open

Public interface for clearing speclj state #139

awkay opened this issue Aug 12, 2015 · 1 comment

Comments

@awkay
Copy link

awkay commented Aug 12, 2015

I'm wanting to use Speclj in clojurescript, and I'm also wanting to use figwheel to hot load tests and run them in the same browser (or a number of browser simultaneously, for that matter). Similar to what Bruce did in his Clojure West conference talk on figwheel.

I've written a sample project that accomplishes this (and it is as nice as I imagined); however, I'm having to manually clear the state of speclj so my tests don't accumulate (every time a cljs file reloads specs, I end up with the old set and a new copy of the reloaded ones).

It wasn't too hard to figure out, but it seems like this is a useful approach that others might want to take, and my test runner feels rather fragile in that I think I'm hacking the internals of speclj to make the running work properly.

I'd be glad to do the coding and documentation to make this a more officially supported thing in speclj, but I'd want to know if you have any suggestions on where/what to place in the code base as a public API for this.

See this section of my runner for details on what I'm doing. Lines 26 and 36/37 are the significant bits...not sure I need both of the latter two now that I think about it.

Tony

@ghost
Copy link

ghost commented Apr 22, 2016

I'm assuming "no" is the answer, give the issue remains open, but has there been any progress on this front? I'm running speclj via the browser using some stuff listed here https://gist.github.com/mike-thompson-day8/8a87349cf69697bfcd64 . But, as mentioned, it seems like speclj holds on to some previously run tests. Run 2 tests (reload) Run 4 tests (reload) Run 6 tests etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants