TestNg runner class | Appium Training|Appium tutorials
50% July Month Discount Avail now

Appium Training Forum

TestNg runner class

S
Suresh Patil Post on 05/05/2019

Hi Aditya,

 

Please explain cucumber TestNG runner class,  As you have coppied pasted code from execisting class.

This would help to solve many problems.

Thanks,

Suresh

 

private TestNGCucumberRunner tcr;

@BeforeClass(alwaysRun = true)
public void setUpClass() throws Exception
{
tcr=new TestNGCucumberRunner(this.getClass());

}
@Test(dataProvider = "features")
public void feature(CucumberFeatureWrapper cucumberFeatureWrapper)
{
tcr.runCucumber(cucumberFeatureWrapper.getCucumberFeature());


}
@DataProvider
public Object[][] features()
{
return tcr.provideFeatures();
}
@AfterClass(alwaysRun = true)
public void tearDownClass()
{
tcr.finish();
}

A
aditya Reply on 07/05/2019

What is the main concern in this class, I mean which method is not clear to you.

i will be happy to explain.