mirror of
https://github.com/corda/corda.git
synced 2024-12-19 04:57:58 +00:00
ENT-11113 Fixed review comments
This commit is contained in:
parent
13e13fd236
commit
795e61807d
@ -330,7 +330,6 @@ jar {
|
|||||||
tasks.named('test', Test) {
|
tasks.named('test', Test) {
|
||||||
maxHeapSize = "3g"
|
maxHeapSize = "3g"
|
||||||
maxParallelForks = (System.env.CORDA_NODE_TESTING_FORKS == null) ? 1 : "$System.env.CORDA_NODE_TESTING_FORKS".toInteger()
|
maxParallelForks = (System.env.CORDA_NODE_TESTING_FORKS == null) ? 1 : "$System.env.CORDA_NODE_TESTING_FORKS".toInteger()
|
||||||
jvmArgs(['--add-opens', 'java.base/java.lang.reflect=ALL-UNNAMED', '--add-opens', 'java.base/java.util=ALL-UNNAMED'])
|
|
||||||
}
|
}
|
||||||
|
|
||||||
publishing {
|
publishing {
|
||||||
|
@ -68,17 +68,16 @@ class ConfigHelperTests {
|
|||||||
|
|
||||||
@Test(timeout = 300_000)
|
@Test(timeout = 300_000)
|
||||||
fun `bad keys are ignored and warned for`() {
|
fun `bad keys are ignored and warned for`() {
|
||||||
val outContent = ByteArrayOutputStream()
|
|
||||||
val errContent = ByteArrayOutputStream()
|
|
||||||
val originalOut = System.out
|
val originalOut = System.out
|
||||||
val originalErr = System.err
|
try {
|
||||||
|
val outContent = ByteArrayOutputStream()
|
||||||
System.setOut(PrintStream(outContent));
|
System.setOut(PrintStream(outContent));
|
||||||
System.setErr(PrintStream(errContent));
|
|
||||||
val config = loadConfig("corda_bad_key" to "2077")
|
val config = loadConfig("corda_bad_key" to "2077")
|
||||||
assertTrue(outContent.toString().contains("(property or environment variable) cannot be mapped to an existing Corda"))
|
assertTrue(outContent.toString().contains("(property or environment variable) cannot be mapped to an existing Corda"))
|
||||||
assertFalse(config?.hasPath("corda_bad_key") ?: true)
|
assertFalse(config?.hasPath("corda_bad_key") ?: true)
|
||||||
|
} finally {
|
||||||
System.setOut(originalOut);
|
System.setOut(originalOut);
|
||||||
System.setErr(originalErr);
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user