在多模块maven项目中引用父pom的Cucumber报告的目标文件夹

时间:2015-11-26 11:56:16

标签: java maven cucumber cucumber-jvm

我有一个多模块maven项目,我在每个模块中生成Cucumber报告。现在我需要将生成的报告的目标位置更改为根pom目录中的目标文件夹。 做这样的事情是否可行?

@CucumberOptions(plugin = { "pretty", "html:path-to-parent-pom/target/testresult"})

对于使用maven-project-info-reports-plugin生成的其他报告,有一个配置选项可以解决此问题。

<aggregate>true</aggregate> 

黄瓜报告中有类似的内容吗?

1 个答案:

答案 0 :(得分:0)

您可以在Cucumber中使用Json Report选项,Maven将阅读Json报告。我想这就是我的所作所为。这里允许Json选项是

 @CucumberOptions(plugin = { "pretty",
        "json:target/testresult.json" } 

我使用此插件进行配置http://damienfremont.com/2015/07/30/how-to-cucumber-test-reporting-plugin-with-maven-and-java/