问题
PhFramework.pizzas.bbqMeatFeast.cheesyBites.LargeTest should execute all tests before proceeding to PhFramework.pizzas.bbqMeatFeast.classicCrust.LargeTest
TestNG seems to be executing the first @Test within all the classes, if i execute only one Test Class at a time it works fine.
testng.xml code: the following will fail, but if i remove one of the classes it works.
Please can somebody advice what could cause this issue?
thanks for your help
回答1:
On line no 4 of your testng.xml, it should be:
<suite name="Suite" parallel="tests" preserve-order="true">
回答2:
preserver-order="true"
should be in the <test>
tag, not the <suite>
tag
回答3:
Notice your packages' names, you have different packages, maybe you have same classes names on two packages?
来源:https://stackoverflow.com/questions/40592208/testng-xml-not-executing-classes-one-by-one