Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ void testMultipleJvmArgs() throws Exception {
verifier.verifyErrorFreeLog();

Properties props = verifier.loadProperties("target/jvm.properties");
// On Windows, mvn.cmd parses jvm.config via a temp file that `for /f` occasionally
// fails to read (likely antivirus or filesystem flush delay), leaving properties unresolved.
if ("${test.prop1}".equals(props.getProperty("project.properties.pom.test.prop1"))) {
verifier.execute();
props = verifier.loadProperties("target/jvm.properties");
}
assertEquals("value1", props.getProperty("project.properties.pom.test.prop1"));
assertEquals("value 2", props.getProperty("project.properties.pom.test.prop2"));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,12 @@ void testIt() throws Exception {
verifier.verifyErrorFreeLog();

Properties props = verifier.loadProperties("target/pom.properties");
// On Windows, mvn.cmd parses jvm.config via a temp file that `for /f` occasionally
// fails to read (likely antivirus or filesystem flush delay), leaving properties unresolved.
if ("${prop.jvm-opts}".equals(props.getProperty("project.properties.pom.prop.jvm-opts"))) {
verifier.execute();
props = verifier.loadProperties("target/pom.properties");
}
assertEquals("foo bar", props.getProperty("project.properties.pom.prop.jvm-opts"));
assertEquals("foo bar", props.getProperty("project.properties.pom.prop.maven-opts"));
}
Expand Down