【发布时间】:2016-12-19 17:42:08
【问题描述】:
您好,我们在 Spock 框架上运行 Geb 测试。我正在尝试使用报告“屏幕截图”在模块中截屏。它不像在 Spec 上那样识别报告功能。我应该如何在模块中截屏。
这是一个模块中的示例代码。
try{
$(By.xpath("//button[@ng-click=\"ok()\"]")).click()
}
catch (Throwable t){
failures.add("\n Could not click on the Ok button after the Ticket created successfully message appeared")
report "Failure"
}
【问题讨论】: