maven-compiler-pluginresponsible for compiling your tests during the phase test-compile. This plugin is configured to fail assembly if any test classes are not compiled. You can experiment with the configuration failOnError. But I doubt that you will get the expected results. The compilation process stops immediately when it encounters a compilation error. Therefore, potentially released free classes may not have been recompiled. Therefore, it will not guarantee that the files .classthat you execute during the phase testwill be “updated” with the corresponding source files .java.
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<executions>
<execution>
<id>default-testCompile</id>
<phase>test-compile</phase>
<goals>
<goal>testCompile</goal>
</goals>
<configuration>
<failOnError>false</failOnError>
</configuration>
</execution>
</executions>
</plugin>
source
share