How to execute multiple testscripts at a time in mobile app testing

i tried running using testng.xml file i kept 5 classes in testng and trying to run but 1st class runs successfully but from 2nd class test cases are terminating in middle of execution.used real android device

please help to know how to resolve it .

is it because of launching the app many times…if yes help me out…thanks

did you follow -> https://appium.io/docs/en/advanced-concepts/parallel-tests/ and configured appiums servers and driver ports correctly?

in general you should have:

  • 5 appium servers where each running at unique port
  • each driver should start against needed appium server with correct port settings

ok thanks.i tried to keep all tests in class and running the test cases but when test fail again i need to launch the app and login i used testng listener…so i tried like this but if any test fail then after relaunching the app it tests gets termianting in middle of execution .
i used only one class here…

<?xml version="1.0" encoding="UTF-8"?>
		<listener class-name="com.funct.Listeners.Itestlistener" />
like this