1、reportNg效果展示
注:截图功能,必须在@aftermethod中引用,才能生成,示例如下
@AfterMethod
public void f8(ITestResult result ){
try {
ReportNGUtils reportNGUtils = new ReportNGUtils();
reportNGUtils.shotScreen(result);
} catch (Exception e) {
}
}

本文详细介绍了如何在ReportNG中使用截图功能,特别是在@aftermethod注解中引用ReportNGUtils类的shotScreen方法来实现自动化测试报告的截图生成。这对于自动化测试人员来说是一个非常实用的技巧,能够帮助他们更好地理解和分析测试结果。
131

被折叠的 条评论
为什么被折叠?



