parent
3e37824861
commit
53961a4104
1 changed files with 6 additions and 5 deletions
|
@ -1,16 +1,17 @@
|
||||||
package app.aaps.plugins.automation.elements
|
package app.aaps.plugins.automation.elements
|
||||||
|
|
||||||
import app.aaps.plugins.automation.triggers.TriggerTestBase
|
import app.aaps.plugins.automation.triggers.TriggerTestBase
|
||||||
import org.junit.jupiter.api.Assertions
|
import com.google.common.truth.Truth.assertThat
|
||||||
import org.junit.jupiter.api.Test
|
import org.junit.jupiter.api.Test
|
||||||
|
import kotlin.test.assertIs
|
||||||
|
|
||||||
class LabelWithElementTest : TriggerTestBase() {
|
class LabelWithElementTest : TriggerTestBase() {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun constructorTest() {
|
fun constructorTest() {
|
||||||
val l = LabelWithElement(rh, "A", "B", InputInsulin())
|
val l = LabelWithElement(rh, "A", "B", InputInsulin())
|
||||||
Assertions.assertEquals("A", l.textPre)
|
assertThat(l.textPre).isEqualTo("A")
|
||||||
Assertions.assertEquals("B", l.textPost)
|
assertThat(l.textPost).isEqualTo("B")
|
||||||
Assertions.assertEquals(InputInsulin::class.java, l.element!!.javaClass)
|
assertIs<InputInsulin>(l.element)
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in a new issue