Hi,
I'm trying to run testng programatically but it's giving error as "Two suites cannot have the same name" even my test suite files has only one file.
my code to run testng programatically.
TestNG testng = new TestNG();
testng.setXmlSuites((List <XmlSuite>)(new Parser("./Suite.xml").parse()));
testng.setListenerClasses(listenrs);
testng.run();
and my test suite file:
<?xml version="1.0" encoding="UTF-8"?>
<suite name="Test Suite" verbose="2" >
<suite-files>
<suite-file path="./src/resources/TicketsWorkspace.xml" />
</suite-files>
</suite>
I need to run actually multiple suites but it's not running even with one. If i change the testng.run() to testng.runSuitesLocally(); its running fine.
any help?