File tree Expand file tree Collapse file tree 3 files changed +7
-19
lines changed
integrationTest/kotlin/org/openziti/api Expand file tree Collapse file tree 3 files changed +7
-19
lines changed Original file line number Diff line number Diff line change @@ -145,9 +145,6 @@ testing {
145145}
146146
147147kotlin {
148- compilerOptions {
149- freeCompilerArgs.add(" -Xjvm-default=all-compatibility" )
150- }
151148 target {
152149 // make sure we can test internal components
153150 compilations.getByName(" integrationTest" ).associateWith(compilations.getByName(" main" ))
Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ class ControllerTests: BaseTest() {
4444
4545 @Test
4646 fun testOttEnrollment () = runTest {
47- val ctrl = Controller (cfg.controller , cfg.sslContext())
47+ val ctrl = Controller .getActiveController (cfg.controllers() , cfg.sslContext())
4848 val session = ctrl.login()
4949 assertEquals(idName, session.identity.name)
5050 ctrl.logout()
Original file line number Diff line number Diff line change @@ -76,24 +76,15 @@ data class IdentityConfig (
7676 /* *
7777 * @inheritDoc
7878 */
79- override fun sslContext (): SSLContext = makeSSLContext(key, cert, caCerts)
79+ override fun sslContext (): SSLContext = makeSSLContext(key() , cert() , caCerts() )
8080
81- internal val key: PrivateKey ? by lazy {
82- id.key?.let {
83- readKey(it)
84- }
85- }
81+ internal fun key (): PrivateKey ? = id.key?.let { readKey(it) }
8682
87- internal val cert: List <X509Certificate > by lazy {
88- id.cert?.let {
89- readCerts(it)
90- } ? : emptyList()
91- }
92-
93- internal val caCerts by lazy {
94- readCerts(id.ca)
95- }
83+ internal fun cert (): List <X509Certificate > = id.cert?.let {
84+ readCerts(it)
85+ } ? : emptyList()
9686
87+ internal fun caCerts () = readCerts(id.ca)
9788
9889 companion object {
9990 val jsonMapper: ObjectMapper =
You can’t perform that action at this time.
0 commit comments