[英]Maven is not using failsafe plugin for integration tests
When I run mvn clean install
, for the integration-test
phase it does not use the failsafe plugin. 当我运行
mvn clean install
,对于integration-test
阶段,它不使用failsafe插件。
However if i explicilty call the plugin to run the integration test, it works ( mvn failsafe:integration-test
). 但是,如果我明确地调用插件来运行集成测试,它就可以工作(
mvn failsafe:integration-test
)。
How can I make maven use the failsafe plugin when I run mvn clean install
during the integration-test
phase? 当我在
integration-test
阶段运行mvn clean install
时,如何让maven使用failsafe插件?
Quote from official documentation : 从官方文档引用:
To use the Failsafe Plugin, you need to add the following configuration
to your pom.xml
<project>
[...]
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<version>2.11</version>
<executions>
<execution>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
[...]
</project>
Is this what you looking for? 这是你要找的?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.