Disable class data sharing (CDS) for tests

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.
This commit is contained in:
Sam Brannen 2024-05-28 15:58:02 +02:00
parent bad4e18b4d
commit 27985b1439
1 changed files with 1 additions and 1 deletions

View File

@ -64,7 +64,7 @@ class TestConventions {
}
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) {