我正在为 4 个套件执行 selenium-automation,如下所示:
<suite name="allSuites">
<suite-files>
<suite-file path="suite1.xml" />
<suite-file path="suite2.xml" />
<suite-file path="suite3.xml" />
<suite-file path="suite4.xml" />
</suite-files>
</suite>
我正在按如下方式创建报告名称:“extent-report-current-date-time.html”
但是当我执行这个套件时,我会看到第一个套件的范围报告。
范围报告文件还指出:
"The ExtentReports report client for starting reporters and building reports. For most applications, you should have one ExtentReports instance for the entire JVM."
这就是我只收到一份报告的原因吗?
我的 ExtentManager 类:
extent = new ExtentReports();
htmlReporter = new ExtentHtmlReporter(getReportName(config));
ClassLoader classLoader = ExtentReportService.class.getClassLoader();
File extentConfigFile = new File(classLoader.getResource("extent-config.xml").getFile());
htmlReporter.loadXMLConfig(extentConfigFile);
htmlReporter.setAppendExisting(true);
extent.attachReporter(htmlReporter);
extent.setSystemInfo("Environment", config.getAutomationServer());
这个问题有转机吗?或者我应该一个一个地执行我的测试用例?