You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by ti...@apache.org on 2020/05/16 21:37:44 UTC

[maven-surefire] branch SUREFIRE-1733 updated (9bd9558 -> 83e8b16)

This is an automated email from the ASF dual-hosted git repository.

tibordigana pushed a change to branch SUREFIRE-1733
in repository https://gitbox.apache.org/repos/asf/maven-surefire.git.


    omit 9bd9558  [SUREFIRE-1733] Surefire and Failsafe JPMS additions for JUnit 5.x execution
     add 754e4ab  [SUREFIRE-1791] Documentation and the integration test for Spock/Groovy with JUnit5
     add f7c1d0d  Verifier 1.7.2
     add 882ae2c  [jenkinsfile] workspace cleanup before/after run
     add d5bbb3f  [SUREFIRE-1787] Support multiple runners (JUnit4, TestNG, other) and their API in JUnit5 Provider
     add d342819  [.asf.yaml] enabled all merge policies in enabled_merge_buttons
     add 5a1c743  [SUREFIRE-1788] Unhandled native logs in SurefireForkChannel
     add 7468f5c  other ITs should not be so sensitive to TestNG and Mockito Reflection [ERROR]s
     add 35f5eaa  Put XML example for "includes" inside its pre tag
     add 218de3c  included H35
     add feb0efc  [SUREFIRE-1570] Maven-fail-safe doesn't put testing JPMS module on module path
     add d44122a  improved coverage in getEffectiveJvm()
     add 13ff548  support Windows in Surefire1295AttributeJvmCrashesToTestsIT
     new 76b6528  [SUREFIRE-1733] Surefire and Failsafe JPMS additions for JUnit 5.x execution
     new 5d8ebb0  integration test
     new 83e8b16  alter the arg file

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (9bd9558)
            \
             N -- N -- N   refs/heads/SUREFIRE-1733 (83e8b16)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .asf.yaml                                          |   8 +
 Jenkinsfile                                        |  54 +-
 .../maven/plugin/failsafe/IntegrationTestMojo.java |   6 +-
 .../plugin/failsafe/IntegrationTestMojoTest.java   |  10 +-
 .../plugin/surefire/AbstractSurefireMojo.java      | 259 ++++---
 .../maven/plugin/surefire/JdkAttributes.java       |  21 +-
 ...tributes.java => ResolvePathResultWrapper.java} |  28 +-
 .../surefire/SurefireDependencyResolver.java       |  26 +-
 .../surefire/SurefireExecutionParameters.java      |   4 +-
 .../booterclient/DefaultForkConfiguration.java     |   2 +-
 .../plugin/surefire/booterclient/ForkStarter.java  |   6 +-
 .../ModularClasspathForkConfiguration.java         |  60 +-
 .../plugin/surefire/booterclient/Platform.java     |   2 +-
 .../output/NativeStdErrStreamConsumer.java         |  14 +-
 .../output/NativeStdOutStreamConsumer.java         |  16 +-
 .../surefire/extensions/LegacyForkChannel.java     |   4 +-
 .../surefire/extensions/SurefireForkChannel.java   |  13 +-
 .../AbstractSurefireMojoJava7PlusTest.java         |  16 +-
 .../plugin/surefire/AbstractSurefireMojoTest.java  | 862 ++++++++++++++-------
 .../AbstractSurefireMojoToolchainsTest.java        |  77 +-
 .../maven/plugin/surefire/MojoMocklessTest.java    |   4 +-
 .../surefire/SurefireDependencyResolverTest.java   |   9 +-
 .../ModularClasspathForkConfigurationTest.java     |   2 +-
 .../maven/plugin/surefire/extensions/E2ETest.java  |   7 +-
 .../maven/surefire/extensions/ForkChannelTest.java |  15 +-
 .../apache/maven/plugin/surefire/module-info.class | Bin 0 -> 149 bytes
 .../maven/plugin/surefire/SurefirePlugin.java      |   9 +-
 .../src/site/apt/examples/junit-platform.apt.vm    | 241 +++++-
 .../src/site/apt/examples/spock.apt.vm             | 174 +++++
 maven-surefire-plugin/src/site/site.xml            |   1 +
 pom.xml                                            |   4 +-
 .../maven/surefire/extensions/ForkChannel.java     |  10 +-
 .../surefire/extensions/StdOutStreamLine.java      |  28 -
 .../its/CheckTestNgListenerReporterIT.java         |   2 +-
 .../maven/surefire/its/CheckTestNgSuiteXmlIT.java  |   7 +-
 .../maven/surefire/its/CheckTestNgVersionsIT.java  |   2 +-
 .../apache/maven/surefire/its/JUnitPlatformIT.java |   6 +-
 .../surefire/its/MultiModuleProjectWithJPMSIT.java |  65 ++
 .../apache/maven/surefire/its/TwoTestCasesIT.java  |   2 +-
 .../surefire/its/fixture/HelperAssertions.java     |  17 +-
 ...rectConcurrentTestCountIT.java => SpockIT.java} |  19 +-
 .../Surefire1295AttributeJvmCrashesToTestsIT.java  |   6 +-
 ...5IT.java => Surefire1570ModularFailsafeIT.java} |  30 +-
 ...urefire1712ExtractedModulenameWithoutASMIT.java |  16 +-
 .../surefire/its/jiras/Surefire1787JUnit5IT.java   | 122 +++
 .../surefire/its/jiras/Surefire673MockitoIT.java   |   6 +-
 ...fire735ForkFailWithRedirectConsoleOutputIT.java |  19 +-
 .../src/test/java/{ => java9/full/api}/J9IT.java   |   2 +
 .../src/test/java/{ => java9/full/api}/J9Test.java |   2 +
 surefire-its/src/test/resources/junit-4-5/pom.xml  | 166 ++++
 .../src/test/java/pkg/JUnit4Test.java}             |   8 +-
 .../junit-4-5/src/test/java/pkg/JUnit5Test.java    |  10 +
 .../{surefire-1727 => junit5-runner}/pom.xml       |  44 +-
 .../src/test/java/examples/RootTest.java           |  10 +
 .../src/test/java/examples/a/ATest.java            |  10 +
 .../src/test/java/examples/b/BTest.java            |  10 +
 .../src/test/java/pkg/JUnit5Tests.java             |  15 +
 .../{surefire-1727 => junit5-spock}/pom.xml        |  32 +-
 .../src/main/java/pkg/Calculator.java}             |   9 +-
 .../src/test/groovy/pkg/CalculatorTest.groovy      |  26 +
 .../src/test/resources/junit5-testng/pom.xml       |  94 +++
 .../src/test/java/pkg/JUnit5Test.java              |  10 +
 .../src/test/java/pkg/TestNGTest.java}             |   8 +-
 .../com.foo.api/pom.xml                            |   0
 .../src/main/java/com/foo/api/SomeInterface.java   |   0
 .../com.foo.api/src/main/java/module-info.java     |   0
 .../com.foo.impl/pom.xml                           |   0
 .../src/main/java/com/foo/impl/Bar.java            |   0
 .../com.foo.impl/src/main/java/module-info.java    |   0
 .../src/test/java/com/foo/impl/BarIT.java          |   0
 .../src/test/java/com/foo/impl/BarTest.java        |   0
 .../pom.xml                                        |   0
 72 files changed, 2059 insertions(+), 708 deletions(-)
 copy maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/{JdkAttributes.java => ResolvePathResultWrapper.java} (55%)
 create mode 100644 maven-surefire-common/src/test/resources/org/apache/maven/plugin/surefire/module-info.class
 create mode 100644 maven-surefire-plugin/src/site/apt/examples/spock.apt.vm
 delete mode 100644 surefire-extensions-api/src/main/java/org/apache/maven/surefire/extensions/StdOutStreamLine.java
 create mode 100644 surefire-its/src/test/java/org/apache/maven/surefire/its/MultiModuleProjectWithJPMSIT.java
 copy surefire-its/src/test/java/org/apache/maven/surefire/its/jiras/{Surefire1055CorrectConcurrentTestCountIT.java => SpockIT.java} (69%)
 copy surefire-its/src/test/java/org/apache/maven/surefire/its/jiras/{Surefire1585IT.java => Surefire1570ModularFailsafeIT.java} (64%)
 create mode 100644 surefire-its/src/test/java/org/apache/maven/surefire/its/jiras/Surefire1787JUnit5IT.java
 rename surefire-its/src/test/resources/java9-full-api/src/test/java/{ => java9/full/api}/J9IT.java (98%)
 rename surefire-its/src/test/resources/java9-full-api/src/test/java/{ => java9/full/api}/J9Test.java (98%)
 create mode 100644 surefire-its/src/test/resources/junit-4-5/pom.xml
 copy surefire-its/src/test/resources/{fail-fast-junit/src/test/java/pkg/ETest.java => junit-4-5/src/test/java/pkg/JUnit4Test.java} (52%)
 create mode 100644 surefire-its/src/test/resources/junit-4-5/src/test/java/pkg/JUnit5Test.java
 copy surefire-its/src/test/resources/{surefire-1727 => junit5-runner}/pom.xml (62%)
 create mode 100644 surefire-its/src/test/resources/junit5-runner/src/test/java/examples/RootTest.java
 create mode 100644 surefire-its/src/test/resources/junit5-runner/src/test/java/examples/a/ATest.java
 create mode 100644 surefire-its/src/test/resources/junit5-runner/src/test/java/examples/b/BTest.java
 create mode 100644 surefire-its/src/test/resources/junit5-runner/src/test/java/pkg/JUnit5Tests.java
 copy surefire-its/src/test/resources/{surefire-1727 => junit5-spock}/pom.xml (73%)
 copy surefire-its/src/test/resources/{surefire-1185/src/test/java/pkg/RunningTest.java => junit5-spock/src/main/java/pkg/Calculator.java} (90%)
 create mode 100644 surefire-its/src/test/resources/junit5-spock/src/test/groovy/pkg/CalculatorTest.groovy
 create mode 100644 surefire-its/src/test/resources/junit5-testng/pom.xml
 create mode 100644 surefire-its/src/test/resources/junit5-testng/src/test/java/pkg/JUnit5Test.java
 copy surefire-its/src/test/resources/{fail-fast-testng/src/test/java/pkg/ETest.java => junit5-testng/src/test/java/pkg/TestNGTest.java} (57%)
 copy surefire-its/src/test/resources/{maven-multimodule-project-with-jpms => surefire-1570}/com.foo.api/pom.xml (100%)
 copy surefire-its/src/test/resources/{maven-multimodule-project-with-jpms => surefire-1570}/com.foo.api/src/main/java/com/foo/api/SomeInterface.java (100%)
 copy surefire-its/src/test/resources/{maven-multimodule-project-with-jpms => surefire-1570}/com.foo.api/src/main/java/module-info.java (100%)
 copy surefire-its/src/test/resources/{maven-multimodule-project-with-jpms => surefire-1570}/com.foo.impl/pom.xml (100%)
 copy surefire-its/src/test/resources/{maven-multimodule-project-with-jpms => surefire-1570}/com.foo.impl/src/main/java/com/foo/impl/Bar.java (100%)
 copy surefire-its/src/test/resources/{maven-multimodule-project-with-jpms => surefire-1570}/com.foo.impl/src/main/java/module-info.java (100%)
 copy surefire-its/src/test/resources/{maven-multimodule-project-with-jpms => surefire-1570}/com.foo.impl/src/test/java/com/foo/impl/BarIT.java (100%)
 copy surefire-its/src/test/resources/{maven-multimodule-project-with-jpms => surefire-1570}/com.foo.impl/src/test/java/com/foo/impl/BarTest.java (100%)
 copy surefire-its/src/test/resources/{maven-multimodule-project-with-jpms => surefire-1570}/pom.xml (100%)


[maven-surefire] 03/03: alter the arg file

Posted by ti...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

tibordigana pushed a commit to branch SUREFIRE-1733
in repository https://gitbox.apache.org/repos/asf/maven-surefire.git

commit 83e8b16127923f599de8c4d33da5b87fef6d580f
Author: tibordigana <ti...@apache.org>
AuthorDate: Sat May 16 23:37:24 2020 +0200

    alter the arg file
---
 .../plugin/surefire/AbstractSurefireMojo.java      |  7 +--
 .../ModularClasspathForkConfiguration.java         | 60 ++++++++++++----------
 .../ModularClasspathForkConfigurationTest.java     |  2 +-
 3 files changed, 39 insertions(+), 30 deletions(-)

diff --git a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
index b1197e1..b2d5ba2 100644
--- a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
+++ b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/AbstractSurefireMojo.java
@@ -1407,8 +1407,8 @@ public abstract class AbstractSurefireMojo
         }
     }
 
-    private boolean canExecuteProviderWithModularPath( Platform platform,
-                                                       ResolvePathResultWrapper resolvedJavaModularityResult )
+    private boolean canExecuteProviderWithModularPath( @Nonnull Platform platform,
+                                                       @Nonnull ResolvePathResultWrapper resolvedJavaModularityResult )
     {
         return useModulePath()
                 && platform.getJdkExecAttributesForTests().isJava9AtLeast()
@@ -2410,7 +2410,8 @@ public abstract class AbstractSurefireMojo
                     reuseForks,
                     platform,
                     getConsoleLogger(),
-                    forkNode );
+                    forkNode,
+                    resolvedJavaModularityResult.isMainModuleDescriptor() );
         }
         else if ( getClassLoaderConfiguration().isManifestOnlyJarRequestedAndUsable() )
         {
diff --git a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/ModularClasspathForkConfiguration.java b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/ModularClasspathForkConfiguration.java
index d659a6c..6f33326 100644
--- a/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/ModularClasspathForkConfiguration.java
+++ b/maven-surefire-common/src/main/java/org/apache/maven/plugin/surefire/booterclient/ModularClasspathForkConfiguration.java
@@ -55,6 +55,8 @@ import static org.apache.maven.surefire.util.internal.StringUtils.NL;
 public class ModularClasspathForkConfiguration
         extends DefaultForkConfiguration
 {
+    private final boolean mainModuleDescriptor;
+
     @SuppressWarnings( "checkstyle:parameternumber" )
     public ModularClasspathForkConfiguration( @Nonnull Classpath bootClasspath,
                                               @Nonnull File tempDirectory,
@@ -69,11 +71,14 @@ public class ModularClasspathForkConfiguration
                                               boolean reuseForks,
                                               @Nonnull Platform pluginPlatform,
                                               @Nonnull ConsoleLogger log,
-                                              @Nonnull ForkNodeFactory forkNodeFactory )
+                                              @Nonnull ForkNodeFactory forkNodeFactory,
+                                              boolean mainModuleDescriptor )
     {
         super( bootClasspath, tempDirectory, debugLine, workingDirectory, modelProperties, argLine,
             environmentVariables, excludedEnvironmentVariables, debug, forkCount, reuseForks, pluginPlatform, log,
             forkNodeFactory );
+
+        this.mainModuleDescriptor = mainModuleDescriptor;
     }
 
     @Override
@@ -167,39 +172,42 @@ public class ModularClasspathForkConfiguration
                         .append( NL );
             }
 
-            args.append( "--patch-module" )
-                    .append( NL )
-                    .append( moduleName )
-                    .append( '=' )
-                    .append( '"' )
-                    .append( replace( patchFile.getPath(), "\\", "\\\\" ) )
-                    .append( '"' )
-                    .append( NL );
-
-            for ( String pkg : packages )
+            if ( mainModuleDescriptor )
             {
-                args.append( "--add-exports" )
+                args.append( "--patch-module" )
+                        .append( NL )
+                        .append( moduleName )
+                        .append( '=' )
+                        .append( '"' )
+                        .append( replace( patchFile.getPath(), "\\", "\\\\" ) )
+                        .append( '"' )
+                        .append( NL );
+
+                for ( String pkg : packages )
+                {
+                    args.append( "--add-exports" )
+                            .append( NL )
+                            .append( moduleName )
+                            .append( '/' )
+                            .append( pkg )
+                            .append( '=' )
+                            .append( "ALL-UNNAMED" )
+                            .append( NL );
+                }
+
+                args.append( "--add-modules" )
+                        .append( NL )
+                        .append( moduleName )
+                        .append( NL );
+
+                args.append( "--add-reads" )
                         .append( NL )
                         .append( moduleName )
-                        .append( '/' )
-                        .append( pkg )
                         .append( '=' )
                         .append( "ALL-UNNAMED" )
                         .append( NL );
             }
 
-            args.append( "--add-modules" )
-                    .append( NL )
-                    .append( moduleName )
-                    .append( NL );
-
-            args.append( "--add-reads" )
-                    .append( NL )
-                    .append( moduleName )
-                    .append( '=' )
-                    .append( "ALL-UNNAMED" )
-                    .append( NL );
-
             args.append( startClassName );
 
             String argsFileContent = args.toString();
diff --git a/maven-surefire-common/src/test/java/org/apache/maven/plugin/surefire/booterclient/ModularClasspathForkConfigurationTest.java b/maven-surefire-common/src/test/java/org/apache/maven/plugin/surefire/booterclient/ModularClasspathForkConfigurationTest.java
index cfa7dce..af317c2 100644
--- a/maven-surefire-common/src/test/java/org/apache/maven/plugin/surefire/booterclient/ModularClasspathForkConfigurationTest.java
+++ b/maven-surefire-common/src/test/java/org/apache/maven/plugin/surefire/booterclient/ModularClasspathForkConfigurationTest.java
@@ -68,7 +68,7 @@ public class ModularClasspathForkConfigurationTest
         ModularClasspathForkConfiguration config = new ModularClasspathForkConfiguration( booter, tmp, "", pwd,
                 new Properties(), "",
                 Collections.<String, String>emptyMap(), new String[0], true, 1, true,
-                new Platform(), new NullConsoleLogger(), mock( ForkNodeFactory.class ) );
+                new Platform(), new NullConsoleLogger(), mock( ForkNodeFactory.class ), true );
 
         File patchFile = new File( "target" + separatorChar + "test-classes" );
         File descriptor = new File( tmp, "module-info.class" );


[maven-surefire] 02/03: integration test

Posted by ti...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

tibordigana pushed a commit to branch SUREFIRE-1733
in repository https://gitbox.apache.org/repos/asf/maven-surefire.git

commit 5d8ebb043ec8de2e90d3e42ed0d4db0043d1e807
Author: tibordigana <ti...@apache.org>
AuthorDate: Sat May 16 23:36:11 2020 +0200

    integration test
---
 .../surefire/its/MultiModuleProjectWithJPMSIT.java | 65 ++++++++++++++++++++++
 1 file changed, 65 insertions(+)

diff --git a/surefire-its/src/test/java/org/apache/maven/surefire/its/MultiModuleProjectWithJPMSIT.java b/surefire-its/src/test/java/org/apache/maven/surefire/its/MultiModuleProjectWithJPMSIT.java
new file mode 100644
index 0000000..d7bcae7
--- /dev/null
+++ b/surefire-its/src/test/java/org/apache/maven/surefire/its/MultiModuleProjectWithJPMSIT.java
@@ -0,0 +1,65 @@
+package org.apache.maven.surefire.its;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.apache.maven.surefire.its.fixture.OutputValidator;
+import org.apache.maven.surefire.its.fixture.SurefireJUnit4IntegrationTestCase;
+import org.junit.Test;
+
+import java.util.List;
+
+import static org.fest.assertions.Assertions.assertThat;
+import static org.hamcrest.Matchers.containsString;
+import static org.hamcrest.Matchers.is;
+
+/**
+ * Integration test for <a href="https://issues.apache.org/jira/browse/SUREFIRE-1733">SUREFIRE-1733</a>.
+ */
+public class MultiModuleProjectWithJPMSIT extends SurefireJUnit4IntegrationTestCase
+{
+    @Test
+    public void test() throws Exception
+    {
+        OutputValidator validator = unpack( "maven-multimodule-project-with-jpms" )
+            .debugLogging()
+            .executeVerify()
+            .verifyErrorFreeLog()
+            .assertThatLogLine( containsString( "Lets see JDKModulePath" ), is( 2 ) )
+            .assertThatLogLine( containsString( "Lets see JDKModulePath: null" ), is( 0 ) );
+
+        List<String> lines = validator.loadLogLines( containsString( "Lets see JDKModulePath" ) );
+        int i = 0;
+        for ( String line : lines )
+        {
+            assertThat( line )
+                .contains( "com.foo.api" )
+                .contains( "junit-jupiter-api" )
+                .contains( "junit-jupiter-engine" )
+                .contains( "slf4j-simple" )
+                .contains( "slf4j-api" )
+                .contains( "jakarta.xml.bind-api" )
+                .contains( "jakarta.ws.rs-api" )
+                .contains( "jakarta.persistence-api" );
+
+            assertThat( line )
+                .contains( i++ == 0 ? "test-classes" : "com.foo.impl" );
+        }
+    }
+}


[maven-surefire] 01/03: [SUREFIRE-1733] Surefire and Failsafe JPMS additions for JUnit 5.x execution

Posted by ti...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

tibordigana pushed a commit to branch SUREFIRE-1733
in repository https://gitbox.apache.org/repos/asf/maven-surefire.git

commit 76b65282eca1a53353779632124bb0aaa765a4e6
Author: tibordigana <ti...@apache.org>
AuthorDate: Wed May 6 01:31:12 2020 +0200

    [SUREFIRE-1733] Surefire and Failsafe JPMS additions for JUnit 5.x execution
---
 .../com.foo.api/pom.xml                            |  51 +++++++++++
 .../src/main/java/com/foo/api/SomeInterface.java   |  28 ++++++
 .../com.foo.api/src/main/java/module-info.java     |  28 ++++++
 .../com.foo.impl/pom.xml                           |  85 +++++++++++++++++
 .../src/main/java/com/foo/impl/Bar.java            |  51 +++++++++++
 .../com.foo.impl/src/main/java/module-info.java    |  26 ++++++
 .../src/test/java/com/foo/impl/BarIT.java          |  41 +++++++++
 .../src/test/java/com/foo/impl/BarTest.java        |  41 +++++++++
 .../maven-multimodule-project-with-jpms/pom.xml    | 101 +++++++++++++++++++++
 9 files changed, 452 insertions(+)

diff --git a/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.api/pom.xml b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.api/pom.xml
new file mode 100644
index 0000000..6e1883c
--- /dev/null
+++ b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.api/pom.xml
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~     http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+  -->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>com.foo</groupId>
+        <artifactId>com.foo</artifactId>
+        <version>1.0.0</version>
+    </parent>
+
+    <artifactId>com.foo.api</artifactId>
+    
+    <dependencies>
+        <dependency>
+            <groupId>jakarta.persistence</groupId>
+            <artifactId>jakarta.persistence-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>jakarta.ws.rs</groupId>
+            <artifactId>jakarta.ws.rs-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>jakarta.xml.bind</groupId>
+            <artifactId>jakarta.xml.bind-api</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+        </dependency>
+    </dependencies>
+</project>
diff --git a/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.api/src/main/java/com/foo/api/SomeInterface.java b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.api/src/main/java/com/foo/api/SomeInterface.java
new file mode 100644
index 0000000..43ecf73
--- /dev/null
+++ b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.api/src/main/java/com/foo/api/SomeInterface.java
@@ -0,0 +1,28 @@
+package com.foo.api;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+/**
+ *
+ */
+public interface SomeInterface
+{
+    void doItNow( Class<?> observer );
+}
diff --git a/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.api/src/main/java/module-info.java b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.api/src/main/java/module-info.java
new file mode 100644
index 0000000..95b05f7
--- /dev/null
+++ b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.api/src/main/java/module-info.java
@@ -0,0 +1,28 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+module com.foo.api
+{
+    exports com.foo.api;
+    requires org.slf4j;
+    requires java.persistence;
+    requires java.ws.rs;
+    requires java.xml.bind;
+    requires jakarta.activation;
+}
diff --git a/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/pom.xml b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/pom.xml
new file mode 100644
index 0000000..e151aff
--- /dev/null
+++ b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/pom.xml
@@ -0,0 +1,85 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~     http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+  -->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>com.foo</groupId>
+        <artifactId>com.foo</artifactId>
+        <version>1.0.0</version>
+    </parent>
+
+    <artifactId>com.foo.impl</artifactId>
+    
+    <dependencies>
+        <dependency>
+            <groupId>com.foo</groupId>
+            <artifactId>com.foo.api</artifactId>
+            <version>${project.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-simple</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.junit.jupiter</groupId>
+            <artifactId>junit-jupiter-api</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-compiler-plugin</artifactId>
+                <configuration>
+<!--                    <multiReleaseOutput>true</multiReleaseOutput>-->
+                </configuration>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-jar-plugin</artifactId>
+                <configuration>
+                    <archive>
+                        <manifestEntries>
+<!--                            <Multi-Release>true</Multi-Release>-->
+                        </manifestEntries>
+                    </archive>
+                </configuration>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-failsafe-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>integration-tests</id>
+                        <goals>
+                            <goal>integration-test</goal>
+                            <goal>verify</goal>
+                        </goals>
+                    </execution>
+                </executions>
+            </plugin>
+        </plugins>
+    </build>
+</project>
diff --git a/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/main/java/com/foo/impl/Bar.java b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/main/java/com/foo/impl/Bar.java
new file mode 100644
index 0000000..50009e3
--- /dev/null
+++ b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/main/java/com/foo/impl/Bar.java
@@ -0,0 +1,51 @@
+package com.foo.impl;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import com.foo.api.SomeInterface;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ *
+ */
+public class Bar implements SomeInterface
+{
+    private static final Logger LOG = LoggerFactory.getLogger( Bar.class );
+
+    private boolean weAreAmongModules;
+
+    @Override
+    public void doItNow( Class<?> observer )
+    {
+        ModuleLayer.boot().modules().forEach( m -> {
+            if ( m == observer.getModule() || m == Bar.class.getModule() || m == Logger.class.getModule() )
+            {
+                weAreAmongModules = true;
+            }
+        } );
+        LOG.info( "" );
+        LOG.info( "Let's see if I or SLF4J are among boot layer modules: {}", weAreAmongModules );
+        if ( !weAreAmongModules )
+        {
+            LOG.info( "Maybe we are in child layer? Or this is not module path?" );
+        }
+    }
+}
diff --git a/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/main/java/module-info.java b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/main/java/module-info.java
new file mode 100644
index 0000000..af383c6
--- /dev/null
+++ b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/main/java/module-info.java
@@ -0,0 +1,26 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+module com.foo.impl
+{
+    requires org.slf4j;
+    requires org.slf4j.simple;
+    opens com.foo.impl;
+    requires com.foo.api;
+}
diff --git a/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/test/java/com/foo/impl/BarIT.java b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/test/java/com/foo/impl/BarIT.java
new file mode 100644
index 0000000..43596b7
--- /dev/null
+++ b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/test/java/com/foo/impl/BarIT.java
@@ -0,0 +1,41 @@
+package com.foo.impl;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.Test;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ *
+ */
+public class BarIT
+{
+    private static final Logger LOG = LoggerFactory.getLogger( BarIT.class );
+
+    @Test
+    void shouldPrintModulePath()
+    {
+        Bar bar = new Bar();
+        LOG.info( "======INTEGRATION TEST=======" );
+        LOG.info( "Lets see JDKModulePath: {}", System.getProperty( "jdk.module.path" ) );
+        bar.doItNow( getClass() );
+    }
+}
diff --git a/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/test/java/com/foo/impl/BarTest.java b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/test/java/com/foo/impl/BarTest.java
new file mode 100644
index 0000000..6e392b6
--- /dev/null
+++ b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/com.foo.impl/src/test/java/com/foo/impl/BarTest.java
@@ -0,0 +1,41 @@
+package com.foo.impl;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.Test;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ *
+ */
+public class BarTest
+{
+    private static final Logger LOG = LoggerFactory.getLogger( BarTest.class );
+
+    @Test
+    void shouldPrintModulePath()
+    {
+        Bar bar = new Bar();
+        LOG.info( "======UNIT TEST=======" );
+        LOG.info( "Lets see JDKModulePath: {}", System.getProperty( "jdk.module.path" ) );
+        bar.doItNow( getClass() );
+    }
+}
diff --git a/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/pom.xml b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/pom.xml
new file mode 100644
index 0000000..0f6bc9a
--- /dev/null
+++ b/surefire-its/src/test/resources/maven-multimodule-project-with-jpms/pom.xml
@@ -0,0 +1,101 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  ~ Licensed to the Apache Software Foundation (ASF) under one
+  ~ or more contributor license agreements.  See the NOTICE file
+  ~ distributed with this work for additional information
+  ~ regarding copyright ownership.  The ASF licenses this file
+  ~ to you under the Apache License, Version 2.0 (the
+  ~ "License"); you may not use this file except in compliance
+  ~ with the License.  You may obtain a copy of the License at
+  ~
+  ~     http://www.apache.org/licenses/LICENSE-2.0
+  ~
+  ~ Unless required by applicable law or agreed to in writing,
+  ~ software distributed under the License is distributed on an
+  ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  ~ KIND, either express or implied.  See the License for the
+  ~ specific language governing permissions and limitations
+  ~ under the License.
+  -->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+    <modelVersion>4.0.0</modelVersion>
+
+    <groupId>com.foo</groupId>
+    <artifactId>com.foo</artifactId>
+    <version>1.0.0</version>
+    <packaging>pom</packaging>
+
+    <properties>
+        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+        <maven.compiler.release>${java.specification.version}</maven.compiler.release>
+    </properties>
+
+    <modules>
+        <module>com.foo.api</module>
+        <module>com.foo.impl</module>
+    </modules>
+
+    <dependencyManagement>
+        <dependencies>
+            <dependency>
+                <groupId>jakarta.persistence</groupId>
+                <artifactId>jakarta.persistence-api</artifactId>
+                <version>2.2.3</version>
+            </dependency>
+            <dependency>
+                <groupId>jakarta.ws.rs</groupId>
+                <artifactId>jakarta.ws.rs-api</artifactId>
+                <version>2.1.6</version>
+            </dependency>
+            <dependency>
+                <groupId>jakarta.xml.bind</groupId>
+                <artifactId>jakarta.xml.bind-api</artifactId>
+                <version>2.3.2</version>
+            </dependency>
+            <dependency>
+                <groupId>org.slf4j</groupId>
+                <artifactId>slf4j-api</artifactId>
+                <version>1.8.0-beta2</version>
+            </dependency>
+            <dependency>
+                <groupId>org.slf4j</groupId>
+                <artifactId>slf4j-simple</artifactId>
+                <version>1.8.0-beta2</version>
+            </dependency>
+            <dependency>
+               <groupId>org.junit.jupiter</groupId>
+               <artifactId>junit-jupiter-api</artifactId>
+               <version>5.6.2</version>
+            </dependency>
+        </dependencies>
+    </dependencyManagement>
+
+    <build>
+        <pluginManagement>
+            <plugins>
+                <plugin>
+                    <groupId>org.apache.maven.plugins</groupId>
+                    <artifactId>maven-compiler-plugin</artifactId>
+                    <version>3.8.1</version>
+                </plugin>
+                <plugin>
+                    <groupId>org.apache.maven.plugins</groupId>
+                    <artifactId>maven-surefire-plugin</artifactId>
+                    <version>${surefire.version}</version>
+                </plugin>
+                <plugin>
+                    <groupId>org.apache.maven.plugins</groupId>
+                    <artifactId>maven-jar-plugin</artifactId>
+                    <version>3.2.0</version>
+                </plugin>
+                <plugin>
+                    <groupId>org.apache.maven.plugins</groupId>
+                    <artifactId>maven-failsafe-plugin</artifactId>
+                    <version>${surefire.version}</version>
+                </plugin>
+            </plugins>
+        </pluginManagement>
+    </build>
+</project>