ReportNG HTML报告未更新 [英] ReportNG HTML report not updating
问题描述
我正在尝试使用ReportNG生成预期的HTML报告。我已经包含了必要的jar文件(guice,velocity和reportng),并编写了一个Test类和各种Page Object类。我将必要的侦听器添加到了test.xml文件中。我用Java编写并使用了Selenium和TestNG。我的测试全部成功运行。
I am trying to generate the expected HTML report with ReportNG. I have included the necessary jar files (guice, velocity, and reportng) and written a Test class and various Page Object classes. I added the necessary listeners into the testing.xml file. I have coded in Java and used Selenium and TestNG. My tests all run successfully.
我唯一的问题是报告没有更新。我只用一次测试就跑了一次,以确保它有效。报告已成功生成,并显示已通过一种方法。我添加了4个其他测试,HTML报告仍然只显示了一个方法。我尝试删除旧的HTML报告,但没有生成新报告。
My only problem is that the report is not updating. I ran it once with only one test to make sure it works. The report was generated successfully and shows one method was passed. I added 4 other tests and the HTML report still shows only one method. I tried deleting the old HTML report and no new one has generated.
提前致谢!
推荐答案
要生成reportNG报告,请确保默认的TestNG监听器已被禁用。
To generate reportNG reports please make sure, default TestNG Listeners is disabled.
可以按照以下步骤完成:
It can be done by following the below steps:
- 右键单击项目。
- 右键单击属性
- 单击TestNG。
- 您将找到一个选项禁用默认侦听器,检查checbox
- 单击应用按钮,它将显示为保存项目首选项消息。
- 现在点击确定按钮。
- Right Click on the project.
- Right Click on Properties
- Click on TestNG.
- You will find an option as "Disable default listeners", check the checbox
- Click on "Apply" button, it will show as message as "Project preferences are saved".
- Now Click on "OK" button.
这篇关于ReportNG HTML报告未更新的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!