< prev index next >
jdk/test/java/util/logging/modules/GetResourceBundleTest.java
Print this page
*** 64,77 ****
public void setup() throws Exception {
// compile all modules
for (String mn : modules) {
Path msrc = MOD_SRC_DIR.resolve(mn);
assertTrue(CompilerUtils.compile(msrc, MOD_DEST_DIR,
! "-modulesourcepath", MOD_SRC_DIR.toString()));
}
assertTrue(CompilerUtils.compile(PKG_SRC_DIR, PKG_DEST_DIR,
! "-modulepath", MOD_DEST_DIR.toString(), "-addmods", String.join(",", modules)));
// copy resource files
String[] files = { "m1/p1/resource/p.properties", "m2/p2/resource/p.properties" };
for(String f : files) {
Files.copy(MOD_SRC_DIR.resolve(f), MOD_DEST_DIR.resolve(f), REPLACE_EXISTING);
--- 64,77 ----
public void setup() throws Exception {
// compile all modules
for (String mn : modules) {
Path msrc = MOD_SRC_DIR.resolve(mn);
assertTrue(CompilerUtils.compile(msrc, MOD_DEST_DIR,
! "--module-source-path", MOD_SRC_DIR.toString()));
}
assertTrue(CompilerUtils.compile(PKG_SRC_DIR, PKG_DEST_DIR,
! "--module-path", MOD_DEST_DIR.toString(), "--add-modules", String.join(",", modules)));
// copy resource files
String[] files = { "m1/p1/resource/p.properties", "m2/p2/resource/p.properties" };
for(String f : files) {
Files.copy(MOD_SRC_DIR.resolve(f), MOD_DEST_DIR.resolve(f), REPLACE_EXISTING);
*** 82,93 ****
@Test
public void runWithoutSecurityManager() throws Exception {
int exitValue = executeTestJava(
"-cp", PKG_DEST_DIR.toString(),
! "-mp", MOD_DEST_DIR.toString(),
! "-addmods", String.join(",", modules),
"p3.test.ResourceBundleTest")
.outputTo(System.out)
.errorTo(System.err)
.getExitValue();
assertTrue(exitValue == 0);
--- 82,93 ----
@Test
public void runWithoutSecurityManager() throws Exception {
int exitValue = executeTestJava(
"-cp", PKG_DEST_DIR.toString(),
! "--module-path", MOD_DEST_DIR.toString(),
! "--add-modules", String.join(",", modules),
"p3.test.ResourceBundleTest")
.outputTo(System.out)
.errorTo(System.err)
.getExitValue();
assertTrue(exitValue == 0);
*** 96,107 ****
@Test
public void runWithSecurityManager() throws Exception {
int exitValue = executeTestJava(
"-Djava.security.manager",
"-cp", PKG_DEST_DIR.toString(),
! "-mp", MOD_DEST_DIR.toString(),
! "-addmods", String.join(",", modules),
"p3.test.ResourceBundleTest")
.outputTo(System.out)
.errorTo(System.err)
.getExitValue();
assertTrue(exitValue == 0);
--- 96,107 ----
@Test
public void runWithSecurityManager() throws Exception {
int exitValue = executeTestJava(
"-Djava.security.manager",
"-cp", PKG_DEST_DIR.toString(),
! "--module-path", MOD_DEST_DIR.toString(),
! "--add-modules", String.join(",", modules),
"p3.test.ResourceBundleTest")
.outputTo(System.out)
.errorTo(System.err)
.getExitValue();
assertTrue(exitValue == 0);
< prev index next >