Home > Software design >  Maven run all tests from a package
Maven run all tests from a package

Time:10-12

I have difficulties to run all tests from a package with mvn command. I have tried solution recommended on stack overflow: mvn '-Dtest=de.mypackage.*Test' test but with no success.

Everything is fine with executing specific class or tests but I don't have success with running all tests from the package. Any suggestions?

CodePudding user response:

Try with:

mvn test -Dtest="de.mypackage.*Test"

or

mvn test -Dtest="de.mypackage.**"

If you want to include subpackages:

mvn test '-Dtest=de.mypackage.**.*Test'
  • Related