<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd"> <suite name="suitename" junit="false" verbose="3" parallel="false" thread-count="5" configfailurepolicy="<span style="font-family:Arial;"><span style="font-size: 14px; line-height: 26px;">skip</span></span>" annotations="javadoc" time-out="10000" skipfailedinvocationcounts="true" data-provider-thread-count="5" object-factory="classname" allow-return-values="true"> <!-- name参数为必须 --> <suite-files> <suite-file path="/path/to/suitefile1"></suite-file> <!-- path参数为必须 --> <suite-file path="/path/to/suitefile2"></suite-file> </suite-files> <parameter name="par1" value="value1"></parameter> <!-- name, value参数为必须 --> <parameter name="par2" value="value2"></parameter> <method-selectors> <method-selector> <selector-class name="classname" priority="1"></selector-class> <!-- name参数为必须 --> <script language=" java"></script> <!-- language参数为必须 --> </method-selector> </method-selectors> <test name="testename" junit="false" verbose="3" parallel="false" thread-count="5" annotations="javadoc" time-out="10000" enabled="true" skipfailedinvocationcounts="true" preserve-order="true" allow-return-values="true"> <!-- name参数为必须 --> <parameter name="par1" value="value1"></parameter> <!-- name, value参数为必须 --> <parameter name="par2" value="value2"></parameter> <groups> <define name="xxx"> <!-- name参数为必须 --> <include name="" description="" invocation-numbers="" /> <!-- name参数为必须 --> <include name="" description="" invocation-numbers="" /> </define> <run> <include name="" /> <!-- name参数为必须 --> <exclude name="" /> <!-- name参数为必须 --> </run> <dependencies> <group name="" depends-on=""></group> <!-- name,depends-on均为参数为必须 --> <group name="" depends-on=""></group> </dependencies> </groups> <classes> <class name="classname"> <!-- name参数为必须 --> <methods> <parameter name="par3" value="value3"></parameter> <include name="" description="" invocation-numbers=""></include> <exclude name=""></exclude> </methods> <methods></methods> </class> </classes> <packages> <package name="" /> <!-- name参数为必须 --> <package name=""> <include name="" description="" invocation-numbers=""></include> <exclude name=""></exclude> </package> </packages> <listeners> <listener class-name="classname1" /> <!-- name参数为必须 --> <listener class-name="classname2" /> </listeners> </test> <test></test> </suite> <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd"> <suite name="suitename" junit="false" verbose="3" parallel="false" thread-count="5" configfailurepolicy="<span style="font-family:Arial;"><span style="font-size: 14px; line-height: 26px;">skip</span></span>" annotations="javadoc" time-out="10000" skipfailedinvocationcounts="true" data-provider-thread-count="5" object-factory="classname" allow-return-values="true"> <!-- name参数为必须 --> <suite-files> <suite-file path="/path/to/suitefile1"></suite-file> <!-- path参数为必须 --> <suite-file path="/path/to/suitefile2"></suite-file> </suite-files> <parameter name="par1" value="value1"></parameter> <!-- name, value参数为必须 --> <parameter name="par2" value="value2"></parameter> <method-selectors> <method-selector> <selector-class name="classname" priority="1"></selector-class> <!-- name参数为必须 --> <script language="java"></script> <!-- language参数为必须 --> </method-selector> </method-selectors> <test name="testename" junit="false" verbose="3" parallel="false" thread-count="5" annotations="javadoc" time-out="10000" enabled="true" skipfailedinvocationcounts="true" preserve-order="true" allow-return-values="true"> <!-- name参数为必须 --> <parameter name="par1" value="value1"></parameter> <!-- name, value参数为必须 --> <parameter name="par2" value="value2"></parameter> <groups> <define name="xxx"> <!-- name参数为必须 --> <include name="" description="" invocation-numbers="" /> <!-- name参数为必须 --> <include name="" description="" invocation-numbers="" /> </define> <run> <include name="" /> <!-- name参数为必须 --> <exclude name="" /> <!-- name参数为必须 --> </run> <dependencies> <group name="" depends-on=""></group> <!-- name,depends-on均为参数为必须 --> <group name="" depends-on=""></group> </dependencies> </groups> <classes> <class name="classname"> <!-- name参数为必须 --> <methods> <parameter name="par3" value="value3"></parameter> <include name="" description="" invocation-numbers=""></include> <exclude name=""></exclude> </methods> <methods></methods> </class> </classes> <packages> <package name="" /> <!-- name参数为必须 --> <package name=""> <include name="" description="" invocation-numbers=""></include> <exclude name=""></exclude> </package> </packages> <listeners> <listener class-name="classname1" /> <!-- name参数为必须 --> <listener class-name="classname2" /> </listeners> </test> <test></test> </suite> |