我有maven failsafe插件的以下配置来运行我的集成测试(基于Failsafe Usage Documentation的文档:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<version>2.16</version>
<executions>
<execution>
<id>integration-test</id>
<goals>
<goal>integration-test</goal>
</goals>
</execution>
<execution>
<id>verify</id>
<goals>
<goal>verify</goal>
</goals>
</execution>
</executions>
</plugin>
当我尝试使用以下命令运行单个测试时:
mvn -Dit.test=MyLovelyTest failsafe:integration-test
它没有运行我的测试。它消失了:No tests were executed
如果删除execution
的{{1}}定义,则会按预期执行测试。由于我从官方使用文档中复制了插件def,我想知道插件中是否有错误,或者是我做错了什么?