Hi Gareth, I've used a variety of CLJS-specific frameworks which I'll detail here, together with some links to help you get up and running.
To get you started, here is a good tutorial on using cljs.test together with the doo framework which Alan has mentioned: https://hub.packtpub.com/testing-your-application-cljstest/ This is great for running tests from the command line, and you can try using phantomjs for so-called headless browsing, but I found both of these approaches a little awkward, not to mention. I then found the following article which pointed me in the direction of devcards by Bruce Hauman, the author of figwheel (which I hope you are using as it makes everything a lot easier): Tutorial: https://8thlight.com/blog/eric-smith/2016/10/05/a-testable-clojurescript-setup.html (starts with a tutorial of setting up doo as above, but you can skim through most of this.) Devcards homepage: https://github.com/bhauman/devcards Devcards is generally useful for testing individual React components, and probably UI components in general, but can also be used to run unit tests as explained in the article. The drawbacks are also explained in the article, and somewhere Bruce Hauman had responded to one of the issues (specifically the lack of fixtures) by encouraging the submitter to use his latest framework, cljs-test-display. I only saw that a couple of weeks ago myself and have just installed it. Effectively it lets you run tests in the browser without any of the limitations of Devcards. So far so good I am very happy with it. You can in fact have both (that is Devcards and cljs-test-display) running alongside each other no problem should you require general browser testing (in Devcards) and all other unit tests (in cljs-test-display.) cljs-test-display homepage: https://github.com/bhauman/cljs-test-display The biggest challenge to getting a lot of these running involves fiddling around with your project.clj file, so I'm hoping you're quite proficient with that. If not, let us know and I'm sure someone can help. Happy testing. Ali On Friday, November 9, 2018 at 11:44:57 PM UTC+5:30, Gareth James wrote: > > I'm currently researching different methods for testing clojurescipt code, > specifically unit testing, automated browser testing and code coverage. I'm > specifically trying to find more information about the use of cljs.test and > cljs.spec either individually or together. Could anyone share any > experience they have of using either of these or any other information > about how they are testing their code. > > Thanks > Gareth > -- Note that posts from new members are moderated - please be patient with your first post. --- You received this message because you are subscribed to the Google Groups "ClojureScript" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojurescript+unsubscr...@googlegroups.com. To post to this group, send email to clojurescript@googlegroups.com. Visit this group at https://groups.google.com/group/clojurescript.