Skip to content

Commit 7945396

Browse files
committed
cvm/overlay: (2/2) Fix gc/startup_warnings tests
Adjust the TestDefaultMaxRAMFraction.java startup warning test to match the JDK17 hotspot behavior while keeping the changes isolated under the JDK 8 overlay. - TestDefaultMaxRAMFraction.java: JDK 17 still warns for DefaultMaxRAMFraction, but the warning is emitted by the JDK17 hotspot deprecation path with different wording; update the expected text to the JDK17 hotspot message.
1 parent 7e8f050 commit 7945396

4 files changed

Lines changed: 2 additions & 3 deletions

File tree

cvm.mk

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -440,6 +440,7 @@ endif
440440
$(call overlay_single,jdk8u,hotspot/test/compiler/8004741/Test8004741.java, $(JDK8_SRCROOT))
441441
$(call overlay_single,jdk8u,hotspot/test/compiler/stable/StableConfiguration.java, $(JDK8_SRCROOT))
442442
$(call overlay_single,jdk8u,hotspot/test/testlibrary/whitebox/sun/hotspot/code/NMethod.java, $(JDK8_SRCROOT))
443+
$(call overlay_single,jdk8u,hotspot/test/gc/startup_warnings/TestDefaultMaxRAMFraction.java, $(JDK8_SRCROOT))
443444

444445
-overlay-jtreg:
445446
$(call overlay_single,jdk8u,test/jtreg-ext/requires/VMProps.java, $(JDK8_SRCROOT))

cvm/conf/jtreg_hotspot8_excludes_aarch64.list

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@ gc/metaspace/TestMetaspaceSizeFlags.java
5353
gc/parallelScavenge/AdaptiveGCBoundary.java
5454
gc/startup_warnings/TestCMSForegroundFlags.java
5555
gc/startup_warnings/TestCMSIncrementalMode.java
56-
gc/startup_warnings/TestDefaultMaxRAMFraction.java
5756
gc/startup_warnings/TestDefNewCMS.java
5857
gc/startup_warnings/TestIncGC.java
5958
gc/6581734/Test6581734.java

cvm/conf/jtreg_hotspot8_excludes_x64.list

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ gc/metaspace/TestMetaspaceSizeFlags.java
4747
gc/parallelScavenge/AdaptiveGCBoundary.java
4848
gc/startup_warnings/TestCMSForegroundFlags.java
4949
gc/startup_warnings/TestCMSIncrementalMode.java
50-
gc/startup_warnings/TestDefaultMaxRAMFraction.java
5150
gc/startup_warnings/TestDefNewCMS.java
5251
gc/startup_warnings/TestIncGC.java
5352
gc/6581734/Test6581734.java

cvm/overlay/jdk8u/hotspot/test/gc/startup_warnings/TestDefaultMaxRAMFraction.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ public class TestDefaultMaxRAMFraction {
3636
public static void main(String[] args) throws Exception {
3737
ProcessBuilder pb = ProcessTools.createJavaProcessBuilder("-XX:DefaultMaxRAMFraction=4", "-version");
3838
OutputAnalyzer output = new OutputAnalyzer(pb.start());
39-
output.shouldContain("warning: DefaultMaxRAMFraction is deprecated and will likely be removed in a future release. Use MaxRAMFraction instead.");
39+
output.shouldContain("warning: Option DefaultMaxRAMFraction was deprecated in version 8.0 and will likely be removed in a future release. Use option MaxRAMFraction instead.");
4040
output.shouldNotContain("error");
4141
output.shouldHaveExitValue(0);
4242
}

0 commit comments

Comments
 (0)