You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Gary Gregory <gg...@apache.org> on 2018/08/06 21:57:02 UTC

[SUREFIRE] Is net.jcip.annotations.NotThreadSafe detected in superclasses?

Hi All:

If I annotate a class S with net.jcip.annotations.NotThreadSafe which has
@Test methods, and then declare a bunch of subclasses of S which also
contain @Test methods.

When I run tests for all subclasses of S, will the Maven Surefire plugin:
- Run all @Test methods from S in a single thread?
- Run all @Test methods from subclasses of S in a single thread?

Thank you,
Gary

Re: [SUREFIRE] Is net.jcip.annotations.NotThreadSafe detected in superclasses?

Posted by Gary Gregory <ga...@gmail.com>.
Forgot to say:

<junit5.version>5.2.0</junit5.version>
...
    <dependency>
      <groupId>org.junit.vintage</groupId>
      <artifactId>junit-vintage-engine</artifactId>
      <version>${junit5.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-api</artifactId>
      <version>${junit5.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>com.github.stephenc.jcip</groupId>
      <artifactId>jcip-annotations</artifactId>
      <version>1.0-1</version>
      <scope>test</scope>
    </dependency>

But my tests only use JUnit 4.

Gary

On Mon, Aug 6, 2018 at 3:57 PM Gary Gregory <gg...@apache.org> wrote:

> Hi All:
>
> If I annotate a class S with net.jcip.annotations.NotThreadSafe which has
> @Test methods, and then declare a bunch of subclasses of S which also
> contain @Test methods.
>
> When I run tests for all subclasses of S, will the Maven Surefire plugin:
> - Run all @Test methods from S in a single thread?
> - Run all @Test methods from subclasses of S in a single thread?
>
> Thank you,
> Gary
>