Hi @Pranodayd
Thanks for your reply!!
Are you using selenium grid for parallel execution. As per my understating you were saying "set maxSession=1" for selenium grid. Please correct me,If I understood incorrectly.
If I want to run parallel execution at one machine using TestNG Thread Count concept. Then how would I handle this scenarios.
For ex :
suite name ="Report" parallel="classes" thread-count="2"
class name = "com.testappium.web.scripts.LoginWeb"/>
class name = "com.testappium.android.scripts.LoginAndroidApp"/>
class name = "com.testappium.web.scripts.LogoutWeb"/>
class name = "com.testappium.android.scripts.LogoutAndroidApp"/>
Note: Above TestNG file just a sample but you will understand the logic.
As per above testng file, Two Thread generates at one machine and start execution. Suppose AndroidApp Login script does not complete, but TestNG fired another thread then Login Script session override by logout session.
Could you have any idea how can we handle this.
One thing more
Are you using AndroidDriver to initialize the driver as shown below:
WebDriver driver = new AndroidDriver(new URL("http://127.0.0.1:4723/wd/hub"),cap);
or
AppiumDriver as show below:
WebDriver driver = new AppiumDriver(new URL("http://127.0.0.1:4723/wd/hub"),cap) {
@Override
public WebElement scrollTo(String arg0) {
// TODO Auto-generated method stub
return null;
}
@Override
public WebElement scrollToExact(String arg0) {
// TODO Auto-generated method stub
return null;
}
};
Thanks in advance!!