我正在尝试使用下面的代码(pom.xml - 通过添加配置文件)排除硒测试,但它不起作用,我的问题是我做错了什么?:
我正在运行 mvn clean install
<profiles>
<profile>
<id>local</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<includes>
<!-- Inclure les tests unitaires ici ... -->
</includes>
<excludes>
<exclude>**/selenium/**/*Test.java</exclude> <!-- Exclure les tests Selenium ici ... -->
</excludes>
</configuration>
<executions>
<execution>
<id>surefire-integration-test</id>
<phase>integration-test</phase>
<goals>
<goal>test</goal> <!-- La phase integration-test va lancer les tests... -->
</goals>
<configuration>
<skip>false</skip>
<includes>
<include>**/selenium/**/*Test.java</include> <!-- ... Inclure les tests Selenium ici -->
</includes>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>