You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
provs/src/test/kotlin/org/domaindrivenarchitecture/provs/framework/ubuntu/keys/base/SshKtTest.kt

28 lines
917 B
Kotlin

package org.domaindrivenarchitecture.provs.framework.ubuntu.keys.base
import org.domaindrivenarchitecture.provs.framework.core.Secret
import org.domaindrivenarchitecture.provs.framework.ubuntu.keys.KeyPair
import org.domaindrivenarchitecture.provs.framework.ubuntu.keys.privateSSHSnakeoilKey
import org.domaindrivenarchitecture.provs.framework.ubuntu.keys.publicSSHSnakeoilKey
import org.domaindrivenarchitecture.provs.test.defaultTestContainer
import org.domaindrivenarchitecture.provs.test.tags.ContainerTest
import org.junit.jupiter.api.Test
import org.junit.jupiter.api.Assertions.*
internal class SshKtTest {
@Test
@ContainerTest
fun configureSshKeys() {
// given
val a = defaultTestContainer()
// when
val res = a.configureSshKeys(KeyPair(Secret(publicSSHSnakeoilKey()), Secret(privateSSHSnakeoilKey())))
// then
assertTrue(res.success)
}
}