Skip to content

Commit ca8bba6

Browse files
author
Harold Seigel
committed
8238263: Create at-requires mechanism for containers
Reviewed-by: bobv, iignatyev
1 parent a7fa1b7 commit ca8bba6

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

test/hotspot/jtreg/TEST.ROOT

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,8 @@ requires.properties= \
7575
vm.compiler2.enabled \
7676
vm.musl \
7777
docker.support \
78-
test.vm.gc.nvdimm
78+
test.vm.gc.nvdimm \
79+
jdk.containerized
7980

8081
# Minimum jtreg version
8182
requiredVersion=5.1 b1

test/jdk/TEST.ROOT

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,8 @@ requires.properties= \
5858
vm.hasJFR \
5959
vm.jvmci \
6060
docker.support \
61-
release.implementor
61+
release.implementor \
62+
jdk.containerized
6263

6364
# Minimum jtreg version
6465
requiredVersion=5.1 b1

test/jtreg-ext/requires/VMProps.java

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@ public Map<String, String> call() {
118118
map.put("vm.musl", this::isMusl);
119119
map.put("release.implementor", this::implementor);
120120
map.put("test.vm.gc.nvdimm", this::isNvdimmTestEnabled);
121+
map.put("jdk.containerized", this::jdkContainerized);
121122
vmGC(map); // vm.gc.X = true/false
122123
vmOptFinalFlags(map);
123124

@@ -545,6 +546,11 @@ private String isNvdimmTestEnabled() {
545546
return "" + "true".equalsIgnoreCase(isEnabled);
546547
}
547548

549+
private String jdkContainerized() {
550+
String isEnabled = System.getenv("TEST_JDK_CONTAINERIZED");
551+
return "" + "true".equalsIgnoreCase(isEnabled);
552+
}
553+
548554
/**
549555
* Dumps the map to the file if the file name is given as the property.
550556
* This functionality could be helpful to know context in the real

0 commit comments

Comments
 (0)