CMP 0.3.0 features a new goal
clojure.test that runs a
clojure.test test suite directly from Maven using Maven’s classpath. Test reporting looks exactly as you would expect, with both console metrics and JUnit test report-compatible XML file output. Internally, we ported several entire Java test suites to Clojure, and are using CMP’s
clojure.test goal to drive the test runs.
Check it out at https://github.com/vivid-inc/clojure-maven-plugin
Wait, what? The clojure-maven-plugin that I see on Maven Central is
com.theoryinpractise’s and it has executed clojure.test tests for years. What is going on here?
Yes, I know about the name overlap with theoryinpractice’s one, as well as Pallet’s clojure-maven & zi… That is why we took some pains to point out that it is Vivid’s take. The name is purely functional in nature: it tells you that it is a Maven plugin that specializes in Clojure, which helps keep downward pressure on cognitive fatigue when poring over long build logs, for example.
The com.theoryinpractice plugin you mention didn’t satisfy our needs so we wrote our own, but in a general form that hopefully is of use to others as well. In terms of build log output and such developer ergonomics, IMHO Vivid CMP’s test reporting style matches that of Maven’s own Java test runners.
Can you be more specific about why “The com.theoryinpractice plugin you mention didn’t satisfy [y]our needs” and what, specifically, is different about Vivid’s?
I’m mostly curious because all of Clojure itself and all its Contrib libraries have been happily using the current Clojure Maven Plugin for years.
Good question! The most salient key points might be:
- Runs tests in a sub-process by constructing a command-line invocation.
- Runs test in-process directly in Maven, providing configurable access to the Java classpath of the Maven project, and reducing build time, among other things.
- Uses weavejester’s eftest under the hood, in part for more legible error reporting.
It isn’t meant as a replacement of existing tooling… And I learned something new today
This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.