selenium - 在 ReportNG 中未获取 TestNG 的报告

标签 selenium report automated-tests testng reportng

我正在 eclipse 中执行 testng,我想在 reportNG 中生成报告。为此,我已经包含了 guice-3.0、reportng-1.1.3、velocity-dep-1.4 jar 文件并在 xml 文件中添加了监听器 另外,我还禁用了 eclipse 中的默认 TestNG 监听器。 毕竟我没有在 ReportNG 中收到报告。我还需要做什么?

这是 xml 代码......

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">  

<suite name="Registration" verbose="1" preserve-order="true">

<parameter name="Suitename" value="Registration" />

   <listeners>
    <listener class-name="org.uncommons.reportng.HTMLReporter" />
     <listener class-name="org.uncommons.reportng.JUnitXMLReporter" />
  </listeners>

 <test name="Search">
    <classes>
    <class name="com.tcs.medmantra.reg.Search"/>
  </classes>
 </test> 

</suite> 

提前致谢......

最佳答案

  1. 您必须首先通过将 testng.xml 作为 TestNG 套件 运行来运行测试。

  2. 然后刷新项目。

  3. 现在转到test-output文件夹-->html-->index.html(使用网络浏览器打开)

    <

关于selenium - 在 ReportNG 中未获取 TestNG 的报告,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19994740/

相关文章:

python - Selenium 将数据抓取到 pandas 数据框

c# - Activereports - 如何转到查看器中的特定页面?

MySQL 报告 - 编辑器

Python测试整个脚本

windows-phone-7 - 如何获取 applicationiconbar 按钮并自动单击它以进行 Windows Phone 7 ui 自动化测试?

java - 从表值动态生成 CSS 选择器

javascript - Protractor - 失败 : stale element reference: element is not attached to the page document

python - 在 python selenium 中使用 get_attribute() 查找 xpath

python - 适合初学者的 OpenERP 报告创建

java - 使用 Appium 安装并跳过未经验证的应用程序消息