maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tibor Digana (JIRA)" <>
Subject [jira] [Commented] (SUREFIRE-1426) Fork crash doesn't fail build with -Dmaven.test.failure.ignore=true
Date Thu, 05 Oct 2017 08:39:00 GMT


Tibor Digana commented on SUREFIRE-1426:

If this log did not happen in {{target/surefire-reports}}, you would not know it and you would
blindly think everything was okay but it was not. Then stop using {{-Dmaven.test.failure.ignore=true}}
and do not use {{Freestyle in Jenkins}} because this style implicitly sets {{maven.test.failure.ignore}}
to {{true}. Pls set it to {{false}}. Again it is highly ubrecommended to use such property
at all!

> Fork crash doesn't fail build with -Dmaven.test.failure.ignore=true
> -------------------------------------------------------------------
>                 Key: SUREFIRE-1426
>                 URL:
>             Project: Maven Surefire
>          Issue Type: Bug
>          Components: process forking
>            Reporter: Dan Berindei
>            Assignee: Tibor Digana
>         Attachments: surefire-1426-test.tar.gz
> We have a reactor with many modules, and also a few random test failures. We want to
run the tests of all the modules even if a test failed in the core module, so we use {{mvn
-Dmaven.test.failure.ignore=true}}. {{mvn --fail-at-end}} only builds the modules that do
not depend on the module with a failed test.
> The problem is that fork crashes like this one are written to the surefire reports, so
Jenkins ignores them:
> {noformat}
> org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the
forked process
> Unable to load category: stress
> 	at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(
> 	at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(
> 	at
> 	at
> 	at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(
> 	at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(
> 	at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(
> 	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(
> 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(
> 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(
> 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(
> 	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(
> 	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(
> 	at
> 	at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(
> 	at org.apache.maven.DefaultMaven.doExecute(
> 	at org.apache.maven.DefaultMaven.doExecute(
> 	at org.apache.maven.DefaultMaven.execute(
> 	at org.apache.maven.cli.MavenCli.execute(
> 	at org.apache.maven.cli.MavenCli.doMain(
> 	at org.apache.maven.cli.MavenCli.main(
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(
> 	at java.lang.reflect.Method.invoke(
> 	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(
> 	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(
> 	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(
> 	at org.codehaus.plexus.classworlds.launcher.Launcher.main({noformat}

This message was sent by Atlassian JIRA

View raw message