Wednesday, 19 September 2018

TestNG | Running suite file programmatically

public class MainTest {
    public static void main(String[] args){
    List<String> file = new ArrayList<String>();
    file.add("D:/Selenium_workspace/Framework/src/Framework.xml");
    TestNG testNG = new TestNG();
    testNG.setTestSuites(file);
    testNG.run();}
}