{"id":804,"date":"2023-03-01T06:42:24","date_gmt":"2023-02-28T22:42:24","guid":{"rendered":"https:\/\/www.appblog.cn\/?p=804"},"modified":"2023-04-05T17:39:42","modified_gmt":"2023-04-05T09:39:42","slug":"testng-suite-test","status":"publish","type":"post","link":"https:\/\/www.appblog.cn\/index.php\/2023\/03\/01\/testng-suite-test\/","title":{"rendered":"TestNG\u5957\u4ef6\u6d4b\u8bd5"},"content":{"rendered":"<p>\u6d4b\u8bd5\u5957\u4ef6\u662f\u4e3a\u4e86\u6d4b\u8bd5\u8f6f\u4ef6\u7a0b\u5e8f\u7684\u884c\u4e3a\u6216\u4e00\u7cfb\u5217\u884c\u4e3a\uff0c\u662f\u4e00\u4e2a\u96c6\u5408\uff0c\u652f\u6301\u7075\u6d3b\u914d\u7f6e\u9700\u8981\u8fd0\u884c\u7684\u6d4b\u8bd5\u3002<\/p>\n<p>testng.xml\u4e2d\u4f7f\u7528<suite>\u6839\u6807\u7b7e\u63cf\u8ff0\u4e00\u4e2a\u6d4b\u8bd5\u5957\u4ef6\uff0c\u5957\u4ef6\u5185\u6d4b\u8bd5\u7531\u591a\u4e2a<test>\u533a\u6bb5\u7ec4\u6210\u3002<\/p>\n<p><!-- more --><br \/>\n<suite>\u53ef\u7528\u5c5e\u6027<\/p>\n<p>| \u5c5e\u6027 | \u63cf\u8ff0 |<br \/>\n| :&#8211; | :-: |<br \/>\n| name          | \u6b64\u5957\u4ef6\u7684\u540d\u79f0\uff0c\u8fd9\u662f\u4e00\u4e2a\u5f3a\u5236\u6027\u7684\u5c5e\u6027 |<br \/>\n| verbose       | \u8fd9\u4e2a\u8fd0\u884c\u7ea7\u522b\u6216\u5197\u957f |<br \/>\n| parallel      | \u7531TestNG \u8fd0\u884c\u4e0d\u540c\u7684\u7ebf\u7a0b\u6765\u8fd0\u884c\u6b64\u5957\u4ef6 |<br \/>\n| thread-count  | \u4f7f\u7528\u7684\u7ebf\u7a0b\u6570\uff0c\u5982\u679c\u542f\u7528\u5e76\u884c\u6a21\u5f0f\uff08\u5ffd\u7565\u5176\u4ed6\u65b9\u5f0f\uff09 |<br \/>\n| annotations   | \u5728\u6d4b\u8bd5\u4e2d\u4f7f\u7528\u6ce8\u91ca\u7684\u7c7b\u578b |<br \/>\n| time-out      | \u9ed8\u8ba4\u7684\u8d85\u65f6\u65f6\u95f4\uff0c\u5c06\u7528\u4e8e\u672c\u6b21\u6d4b\u8bd5\u4e2d\u53d1\u73b0\u7684\u6240\u6709\u6d4b\u8bd5\u65b9\u6cd5 |<\/p>\n<p>&#8220;`xml<br \/>\n&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;<br \/>\n&lt;!DOCTYPE suite SYSTEM &quot;http:\/\/testng.org\/testng-1.0.dtd&quot; &gt;<br \/>\n&lt;suite name=&quot;Suite&quot;&gt;<br \/>\n  &lt;test name=&quot;test1&quot;&gt;<br \/>\n    &lt;classes&gt;<br \/>\n       &lt;class name=&quot;cn.appblog.Test1&quot; \/&gt;<br \/>\n    &lt;\/classes&gt;<br \/>\n  &lt;\/test&gt;<br \/>\n  &lt;test name=&quot;test2&quot;&gt;<br \/>\n    &lt;classes&gt;<br \/>\n       &lt;class name=&quot;cn.appblog.Test2&quot; \/&gt;<br \/>\n    &lt;\/classes&gt;<br \/>\n  &lt;\/test&gt;<br \/>\n&lt;\/suite&gt;<br \/>\n&#8220;`<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6d4b\u8bd5\u5957\u4ef6\u662f\u4e3a\u4e86\u6d4b\u8bd5\u8f6f\u4ef6\u7a0b\u5e8f\u7684\u884c\u4e3a\u6216\u4e00\u7cfb\u5217\u884c\u4e3a\uff0c\u662f\u4e00\u4e2a\u96c6\u5408\uff0c\u652f\u6301\u7075\u6d3b\u914d\u7f6e\u9700\u8981\u8fd0\u884c\u7684\u6d4b\u8bd5\u3002 testng.xml\u4e2d [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[224],"tags":[],"class_list":["post-804","post","type-post","status-publish","format-standard","hentry","category-testng"],"_links":{"self":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/804","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/comments?post=804"}],"version-history":[{"count":0,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/posts\/804\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/media?parent=804"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/categories?post=804"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appblog.cn\/index.php\/wp-json\/wp\/v2\/tags?post=804"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}