Skip to content

Commit

Permalink
[SHIRO-895] hazelcast/powermock/guice Java17 compat
Browse files Browse the repository at this point in the history
  • Loading branch information
bmarwell committed Oct 26, 2022
1 parent ca39255 commit f5f1098
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 2 deletions.
25 changes: 25 additions & 0 deletions integration-tests/guice3/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -123,4 +123,29 @@
<scope>test</scope>
</dependency>
</dependencies>

<profiles>
<profile>
<id>jdk16</id>
<activation>
<jdk>[16,)</jdk>
</activation>
<properties>
<!-- needed by guice until it is compatible with jdk16+. -->
<surefire.argLine>--illegal-access=permit</surefire.argLine>
<failsafe.argLine>--illegal-access=permit</failsafe.argLine>
</properties>
</profile>
<profile>
<id>jdk17</id>
<activation>
<jdk>[17,)</jdk>
</activation>
<properties>
<!-- needed by guice until it is compatible with jdk17+. -->
<surefire.argLine>--add-opens java.base/java.lang=ALL-UNNAMED</surefire.argLine>
<failsafe.argLine>--add-opens java.base/java.lang=ALL-UNNAMED</failsafe.argLine>
</properties>
</profile>
</profiles>
</project>
25 changes: 25 additions & 0 deletions integration-tests/guice4/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -128,4 +128,29 @@
<scope>test</scope>
</dependency>
</dependencies>

<profiles>
<profile>
<id>jdk16</id>
<activation>
<jdk>[16,)</jdk>
</activation>
<properties>
<!-- needed by guice until it is compatible with jdk16+. -->
<surefire.argLine>--illegal-access=permit</surefire.argLine>
<failsafe.argLine>--illegal-access=permit</failsafe.argLine>
</properties>
</profile>
<profile>
<id>jdk17</id>
<activation>
<jdk>[17,)</jdk>
</activation>
<properties>
<!-- needed by guice until it is compatible with jdk17+. -->
<surefire.argLine>--add-opens java.base/java.lang=ALL-UNNAMED</surefire.argLine>
<failsafe.argLine>--add-opens java.base/java.lang=ALL-UNNAMED</failsafe.argLine>
</properties>
</profile>
</profiles>
</project>
4 changes: 2 additions & 2 deletions support/hazelcast/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@
<jdk>[8,)</jdk>
</activation>
<properties>
<surefire.argLine> --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED</surefire.argLine>
<failsafe.argLine> --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED</failsafe.argLine>
<surefire.argLine> --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.lang.ref=ALL-UNNAMED</surefire.argLine>
<failsafe.argLine> --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.lang.ref=ALL-UNNAMED</failsafe.argLine>
</properties>
</profile>
</profiles>
Expand Down

0 comments on commit f5f1098

Please sign in to comment.