From d4c3f21bee81c867190efbaef998003fd1fe04ee Mon Sep 17 00:00:00 2001 From: Ryan Haining Date: Wed, 4 Oct 2023 21:08:54 -0700 Subject: [PATCH] Rewrites InputCarePortalEventTest with matchers Issue #2745 --- .../automation/elements/InputCarePortalEventTest.kt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/plugins/automation/src/test/kotlin/app/aaps/plugins/automation/elements/InputCarePortalEventTest.kt b/plugins/automation/src/test/kotlin/app/aaps/plugins/automation/elements/InputCarePortalEventTest.kt index e380c24420..1d875a2cd2 100644 --- a/plugins/automation/src/test/kotlin/app/aaps/plugins/automation/elements/InputCarePortalEventTest.kt +++ b/plugins/automation/src/test/kotlin/app/aaps/plugins/automation/elements/InputCarePortalEventTest.kt @@ -1,19 +1,19 @@ package app.aaps.plugins.automation.elements 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 class InputCarePortalEventTest : TriggerTestBase() { @Test fun labelsTest() { - Assertions.assertEquals(4, InputCarePortalMenu.EventType.labels(rh).size) + assertThat(InputCarePortalMenu.EventType.labels(rh)).hasSize(4) } @Test fun setValueTest() { val cp = InputCarePortalMenu(rh, InputCarePortalMenu.EventType.EXERCISE) - Assertions.assertEquals(InputCarePortalMenu.EventType.EXERCISE, cp.value) + assertThat(cp.value).isEqualTo(InputCarePortalMenu.EventType.EXERCISE) } -} \ No newline at end of file +}