Skip to content

Commit

Permalink
Disable class data sharing (CDS) for tests
Browse files Browse the repository at this point in the history
Prior to this commit, the Gradle build output the following warning
multiple times.

OpenJDK 64-Bit Server VM warning: Sharing is only supported for boot loader classes because bootstrap classpath has been appended

Since we don't need CDS enabled for our tests, I've added `-Xshare:off`
as a JVM argument for our tests to disable CDS.
  • Loading branch information
sbrannen committed May 28, 2024
1 parent bad4e18 commit 27985b1
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ private void configureTests(Project project, Test test) {
}
test.jvmArgs("--add-opens=java.base/java.lang=ALL-UNNAMED",
"--add-opens=java.base/java.util=ALL-UNNAMED",
"-Djava.locale.providers=COMPAT");
"-Djava.locale.providers=COMPAT", "-Xshare:off");
}

private void configureTestRetryPlugin(Project project, Test test) {
Expand Down

0 comments on commit 27985b1

Please sign in to comment.