Merge pull request #7634 from corda/arshad/ent-11316-fix-config-parsing-test

ENT-11316 Fix test failure due to issue in Kotlin 1.9 type inference
This commit is contained in:
Adel El-Beik 2023-12-22 12:19:21 +00:00 committed by GitHub
commit 7b57ccf783
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 3 deletions

View File

@ -188,7 +188,7 @@ private fun Config.getSingleValue(
X500Principal::class -> X500Principal(getString(path))
CordaX500Name::class -> {
when (getValue(path).valueType()) {
ConfigValueType.OBJECT -> getConfig(path).parseAs(onUnknownKeys)
ConfigValueType.OBJECT -> getConfig(path).parseAs(onUnknownKeys) as CordaX500Name
else -> CordaX500Name.parse(getString(path))
}
}

View File

@ -10,7 +10,6 @@ import net.corda.core.utilities.NetworkHostAndPort
import org.assertj.core.api.Assertions.assertThat
import org.assertj.core.api.Assertions.assertThatExceptionOfType
import org.assertj.core.api.Assertions.assertThatThrownBy
import org.junit.Ignore
import org.junit.Test
import java.net.URL
import java.nio.file.Path
@ -109,7 +108,6 @@ class ConfigParsingTest {
}
@Test(timeout=300_000)
@Ignore("TODO JDK17: Fixme")
fun `test CordaX500Name`() {
val name1 = CordaX500Name(organisation = "Mock Party", locality = "London", country = "GB")
testPropertyType<CordaX500NameData, CordaX500NameListData, CordaX500Name>(