JPragma Blog

Pragmatic Developers, Elegant Software

Archive for January 2011

Useful options running “mvn test”

with one comment

There are some very useful command line options you can specify when executing maven tests:

-Dtest=[testname], this allows selective execution of unit tests, instead of running them all. [testname] might be full class name, class name without package, or even wildcard.

-Dsurefire.useFile=false, this will force surefire plugin to write failing test info to stdout instead of file in target/surefire-reports/. Can be a huge time saver.

Written by isaaclevin

January 28, 2011 at 12:58 pm

Posted in Java