maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Piotr Turski (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SUREFIRE-1305) surefire fails on parallel tests when newline character is in test description
Date Sun, 20 Nov 2016 22:11:00 GMT

    [ https://issues.apache.org/jira/browse/SUREFIRE-1305?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15681920#comment-15681920
] 

Piotr Turski commented on SUREFIRE-1305:
----------------------------------------

still a bug. i took the project that reproduces the issue, added:
{code:xml}
   <pluginRepositories>
        <pluginRepository>
            <id>apache.snapshots</id>
            <url>http://repository.apache.org/snapshots/</url>
        </pluginRepository>
    </pluginRepositories>
{code}
and changed version to
{code}
 <version>2.19.2-SNAPSHOT</version>
{code}
and after running tests:
{noformat}
[INFO] Scanning for projects...
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building playground 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- maven-resources-plugin:2.5:resources (default-resources) @ playground ---
[debug] execute contextualize
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /xxxxxxxxx/zohhak_parallel_bug/src/main/resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.5.1:compile (default-compile) @ playground ---
[INFO] No sources to compile
[INFO] 
[INFO] --- maven-resources-plugin:2.5:testResources (default-testResources) @ playground ---
[debug] execute contextualize
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory /xxxxxxxx/zohhak_parallel_bug/src/test/resources
[INFO] 
[INFO] --- maven-compiler-plugin:3.5.1:testCompile (default-testCompile) @ playground ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] --- maven-surefire-plugin:2.19.2-SNAPSHOT:test (default-test) @ playground ---
[INFO] 
[INFO] -------------------------------------------------------
[INFO]  T E S T S
[INFO] -------------------------------------------------------
[INFO] Running testMethod
[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0 s - in testMethod
[INFO] 
[INFO] Results:
[INFO] 
[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
[INFO] 
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.240s
[INFO] Finished at: Sun Nov 20 23:01:58 CET 2016
[INFO] Final Memory: 11M/303M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.19.2-SNAPSHOT:test
(default-test) on project playground: Execution default-test of goal org.apache.maven.plugins:maven-surefire-plugin:2.19.2-SNAPSHOT:test
failed: There was an error in the forked process
[ERROR] org.apache.maven.surefire.testset.TestSetFailedException: Test mechanism :: null
[ERROR] at org.apache.maven.surefire.common.junit4.JUnit4RunListener.rethrowAnyTestMechanismFailures(JUnit4RunListener.java:210)
[ERROR] at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.createRequestAndRun(JUnitCoreWrapper.java:138)
[ERROR] at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.executeEager(JUnitCoreWrapper.java:107)
[ERROR] at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.execute(JUnitCoreWrapper.java:83)
[ERROR] at org.apache.maven.surefire.junitcore.JUnitCoreWrapper.execute(JUnitCoreWrapper.java:75)
[ERROR] at org.apache.maven.surefire.junitcore.JUnitCoreProvider.invoke(JUnitCoreProvider.java:157)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.invokeProviderInSameClassLoader(ForkedBooter.java:300)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:251)
[ERROR] at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:130)
[ERROR] Caused by: java.lang.NullPointerException
[ERROR] at org.apache.maven.surefire.junitcore.ConcurrentRunListener.testStarting(ConcurrentRunListener.java:134)
[ERROR] at org.apache.maven.surefire.common.junit4.JUnit4RunListener.testStarted(JUnit4RunListener.java:93)
[ERROR] at org.junit.runner.notification.SynchronizedRunListener.testStarted(SynchronizedRunListener.java:49)
[ERROR] at org.junit.runner.notification.RunNotifier$3.notifyListener(RunNotifier.java:121)
[ERROR] at org.junit.runner.notification.RunNotifier$SafeNotifier.run(RunNotifier.java:72)
[ERROR] at org.junit.runner.notification.RunNotifier.fireTestStarted(RunNotifier.java:118)
[ERROR] at org.apache.maven.surefire.common.junit4.Notifier.fireTestStarted(Notifier.java:100)
[ERROR] at org.junit.internal.runners.model.EachTestNotifier.fireTestStarted(EachTestNotifier.java:42)
[ERROR] at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:323)
[ERROR] at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
[ERROR] at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
[ERROR] at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
[ERROR] at org.apache.maven.surefire.junitcore.pc.Scheduler$1.run(Scheduler.java:393)
[ERROR] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[ERROR] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[ERROR] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
[ERROR] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
[ERROR] at java.lang.Thread.run(Thread.java:745)
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following
articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException

Process finished with exit code 1

{noformat}

> surefire fails on parallel tests when newline character is in test description
> ------------------------------------------------------------------------------
>
>                 Key: SUREFIRE-1305
>                 URL: https://issues.apache.org/jira/browse/SUREFIRE-1305
>             Project: Maven Surefire
>          Issue Type: Bug
>          Components: Junit 4.7+ (parallel) support
>    Affects Versions: 2.19.1
>            Reporter: Piotr Turski
>            Assignee: Tibor Digana
>
> zohhak runner may create test description with newline character in it. it runs without
any problem with surefire and non-parallel build and with parallel build when there is no
newline char in the description. furthermore it runs fine with plain junit in parallel mode
> * original issue was reported here: https://github.com/piotrturski/zohhak/issues/14
> * project that reproduces the issue: https://github.com/christophpickl/zohhak_parallel_bug
> * working parallel junit tests without surefire: https://github.com/piotrturski/zohhak/commit/806aafc8e09fd843753d2940991f3ca0edd5120d



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message