michael nesterenko michael nesterenko - 1 year ago 215
Java Question

maven skip tests with compilation errors

Are there an option to skip tests with compilation errors? Just ignore them or treat them as failed?

Answer Source

The maven-compiler-plugin is responsible for compiling your tests during the test-compile phase. This plugin is configured to fail the build if any test classes fail to compile. You could experiment with the failOnError configuration. But I doubt you'll get the results you expect. The compilation process stops immediately when it encounters a compilation error. So potentially issue free classes may not have been re-compiled. Therefore there will be no guarantee the .class files you execute during the test phase will be 'up to date' with the corresponding .java source files.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download