I have a testNG suite where I want all methods in all classes I've specified to be run:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "http://ift.tt/19x2mI9">
<suite thread-count="20" name="SmokeTestSuite" parallel="methods">
<test name="Test1" group-by-instances="true" junit="true">
<classes>
<class name="Class1"/>
<class name="Class2"/>
<class name="Class3"/>
</classes>
</test>
</suite>
However this doesn't run all the methods, its doing it one class at a time.
If i write my suite as the following it works - however having to duplicate code in this way isn't appealing/very time consuming.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "http://ift.tt/19x2mI9">
<suite thread-count="20" name="SmokeTestSuite" parallel="tests">
<test name="Test1" group-by-instances="true" junit="true">
<classes>
<class name="Class1"/>
<methods>
<include name="myAutoTest1"/>
</methods>
</classes>
</test>
<test name="Test2" group-by-instances="true" junit="true">
<classes>
<class name="Class1"/>
<methods>
<include name="myAutoTest2"/>
</methods>
</classes>
</test>
<test name="Test3" group-by-instances="true" junit="true">
<classes>
<class name="Class1"/>
<methods>
<include name="myAutoTest3"/>
</methods>
</classes>
</test>
<test name="Test4" group-by-instances="true" junit="true">
<classes>
<class name="Class2"/>
<methods>
<include name="myAutoTest4"/>
</methods>
</classes>
</test>
<test name="Test5" group-by-instances="true" junit="true">
<classes>
<class name="Class3"/>
<methods>
<include name="myAutoTest5"/>
</methods>
</classes>
</test>
<test name="Test6" group-by-instances="true" junit="true">
<classes>
<class name="Class3"/>
<methods>
<include name="myAutoTest6"/>
</methods>
</classes>
</test>
</suite>
Any ideas to why this could be occuring?
Thanks
Aucun commentaire:
Enregistrer un commentaire