diff --git a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/ForkStarter.java b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/ForkStarter.java index a999069804..c2a74a4071 100644 --- a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/ForkStarter.java +++ b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/ForkStarter.java @@ -653,6 +653,12 @@ private RunResult fork( Object testSet, PropertiesWrapper providerProperties, Fo { runResult = timeout( reporter.getGlobalRunStatistics().getRunResult() ); } + else if ( forkClient.isErrorInFork() ) + { + final StackTraceWriter stackTrace = forkClient.getErrorInFork(); + booterForkException = + new SurefireBooterForkException( stackTrace.writeTraceToString() ); + } else if ( result != SUCCESS ) { booterForkException =