jeudi 25 décembre 2014

How to run multiple test classes or test methods using Maven?

In order to run all Maven tests, we can use:



mvn clean test


If we want to run specific test class, we can use:



mvn clean test -Dtest=className


If we want to run specific method from specific test class, we can use:



mvn clean test -Dtest=className#methodName


But I want to run:



  1. multiple test classes(not all that belong to src\test\java)

  2. multiple test methods from specific test class(not all test methods of specific test class that belong to src\test\java)


Are there Maven commands using which I can achieve above two?


Aucun commentaire:

Enregistrer un commentaire