[
https://issues.apache.org/jira/browse/SUREFIRE-1373?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16096292#comment-16096292
]
Tibor Digana edited comment on SUREFIRE-1373 at 7/21/17 2:08 PM:
-----------------------------------------------------------------
It looks like both groups run one after another.
[Here|https://github.com/apache/maven-surefire/blob/master/surefire-providers/surefire-junit47/src/main/java/org/apache/maven/surefire/junitcore/pc/ParallelComputerBuilder.java#L579]
{{suiteSuites, suiteClasses}} should be encapsulated in one ParentRunner and
{{createSuite( notParallelRunners )}} in second ParentRunner.
If you guys want to contribute, you can check it out and run the build {{mvn
install}}. Not sure if the tests fail after this change.
was (Author: tibor17):
It looks like both groups run one after another.
[Here|https://github.com/apache/maven-surefire/blob/master/surefire-providers/surefire-junit47/src/main/java/org/apache/maven/surefire/junitcore/pc/ParallelComputerBuilder.java#L579]
{{suiteSuites, suiteClasses}} should be encapsulated in one ParentRunner and
{{createSuite( notParallelRunners )}}.
If you guys want to contribute, you can check it out and run the build {{mvn
install}}. Not sure if the tests fail after this change.
> Tests annotated with @NotThreadSafe are not executed in isolation
> -----------------------------------------------------------------
>
> Key: SUREFIRE-1373
> URL: https://issues.apache.org/jira/browse/SUREFIRE-1373
> Project: Maven Surefire
> Issue Type: Bug
> Components: Maven Surefire Plugin
> Affects Versions: 2.20
> Reporter: Sebastian Kirsch
> Assignee: Tibor Digana
> Fix For: 2.20.1
>
>
> The [surefire
> documentation|http://maven.apache.org/components/surefire/maven-failsafe-plugin/examples/fork-options-and-parallel-execution.html]
> states that
> bq. you can apply the JCIP annotation @net.jcip.annotations.NotThreadSafe on
> the Java class of JUnit test (pure test class, Suite, Parameterized, etc.) in
> order to execute it in single Thread instance. The Thread has name
> maven-surefire-plugin@NotThreadSafe and it is executed at the end of the test
> run.
> However, the thread is run in parallel to the other tests being executed,
> which contradicts the documentation and defeats the purpose of running tests
> sequentially in a single thread.
> See https://github.com/sebastiankirsch/surefire-nonthreadsafe for a test case.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)