TestNG测试结果为0

时间:2015-03-17 12:39:39

标签: testng

用testNG运行selenium rc得到这样的结果

  [TestNG] Running:
  /tmp/testng-eclipse--383064893/testng-customsuite.xml
===============================================
    Default test
    Tests run: 0, Failures: 0, Skips: 0
===============================================    

测试套件结果

===============================================
Default suite
Total tests run: 0, Failures: 0, Skips: 0  
===============================================

输出命令

[TestNG] Time taken by org.testng.reporters.XMLReporter@68e4a47: 16 ms
[TestNG] Time taken by org.testng.reporters.jq.Main@38c8c892: 38 ms
[TestNG] Time taken by org.testng.reporters.JUnitReportReporter@1abe675c: 0 ms
[TestNG] Time taken by org.testng.reporters.SuiteHTMLReporter@741bb804: 13 ms
[TestNG] Time taken by org.testng.reporters.EmailableReporter2@665d7a8d: 5 ms
[TestNG] Time taken by [FailedReporter passed=0 failed=0 skipped=0]: 0 ms

2 个答案:

答案 0 :(得分:0)

Testng没有找到带有测试的类。从工作示例开始,例如:http://www.mkyong.com/tutorials/testng-tutorials/

答案 1 :(得分:0)

如果您有一个testng.xml,请不要忘记将您的项目指向该xml文件,因为如果您没有,那么TestNG将以编程方式创建一个xml。

答案中的详细信息:How to make TestNG to add parameters to testng-customsuite.xml?