Im trying to run some selected tests from my Test class based on the test case name.
Below is an outline of my test class
----GlobalTests.java----
@Test
public void myTest_India(){ --- }
@Test
public void myTest_Germany() { --- }
----GlobalIntegrationTests.java----
@Test
public void myIntegrationTest_India(){ --- }
@Test
public void myIntegrationTest_Germany() { --- }
How do I instruct my maven to run only 'India' tests?
I've tried in maven surefire plugin as below
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0-M5</version>
<configuration>
<includes>
<include>%regex[*Test_India*]</include>
</includes>
</configuration>
</plugin>
But seems like this configuration is for selecting test class names and NOT test names.
Thanks in advance.