Technical tooling for making better software

Ripping seams is easy when you use the right tool.

David R. MacIver has a list of some things that might help you make better software. Some of the things, like continuous integration, require technical tooling in addition to adopting the practices.

If you agree with David’s list – and I do - this raises a question: does your technical stack provide the tooling needed for implementing David’s suggestions? In my case, do these tools exist for Clojure and ClojureScript? Let’s find out.

Continuous integration. No problems here: CI servers are mostly language-agnostic. If you want a hosted solution, there’s e.g. Travis and Circle, and if you prefer running your own, Jenkins is always there.

Local automated tests. For Clojure, things are okay. Test runners are not perfect, but there’s a reasonable workflow for running single tests in common editors like Emacs and Cursive, and running the whole test suite obviously works. For ClojureScript, there’s a workable setup for the whole test suite. In theory, the same editor workflow should work for ClojureScript, but in practice I’ve always encountered problems with the ClojureScript REPL.

Code coverage. For Clojure, there’s cloverage, although I’ve had some trouble with making it work with all the projects. As far as I know, there’s nothing for ClojureScript yet. Maybe something could be whipped up with Istanbuland remap-istanbul?

Property-based testing. There’s test.check, which David ranks as very good. clojure.spec’s generator support makes it even nicer. It works with both Clojure and ClojureScript.

Static analysis. Cursive does some in-editor analysis with both Clojure and ClojureScript. For Clojure, there’s Eastwood, which does not work with every project, but it is nice when it works. There’s also kibit, which is less useful, but also works with ClojureScript.

Production error monitoring. I’ve actually never done this with Clojure or ClojureScript, but I know that there’s at least Sentry tooling for various Java and Clojure logging libraries. Sentry also supports JavaScript error tracking, which might be good enough for ClojureScript.

Auto formatting and style checking. At least both Cursive and Emacs have support for reformatting Clojure(Script) code. cljfmt can both check and format your code and lein-bikeshed checks some things as well. They’re not quite as advanced as something like ESLint, though.

Overall, I’d rate the situation as okay but not amazing. If you look at David’s list, having the right processes and the right culture will have much bigger impact than having good tools. On the other hand, changing any processes involving tools is easier when the tools actually work.


Comments or questions? Send me an e-mail.


Want to get these articles to your inbox? Subscribe to the newsletter: