TestProject Forum
Powered by leading experts in the test automation community

Run Appium test with Maven

Hi All,

I am looking for a help on running the appium test with Maven and testng framework. I am able to run the test as testng from eclipse and also I am able to run the appium test with ‘mvn -Dtest=test.com.appium.AppiumTest’, but when running the test with ‘mvn clean test’ or ‘mvn test’, appium test does not gets executed. I am running this on window 8.1, testng 6.5.1 with selenium 2.53, JDK 1.8.

I would appreciate your inputs.

Thanks,
Karim

Hello Karim,

I’m not sure if this is directly related to Appium, and even if yes if the information you supplied is enough to troubleshoot this.
However, did you try to put a simple stdout, something like System.out.println("I'm inside the test method") inside the test method to make sure it even runs ?

Also, maven expects your tests to be at /myApp/src/test/java/MyTest.java, looks like yours is under test.com.appium.AppiumTest, and it’s quite strange that when you specify the exact test name it still works for you…

Can you please try moving your test class into the right location ?