From 9f5333645ec8704463e13a0bc63504c26fcc77fb Mon Sep 17 00:00:00 2001 From: Ryan Haining Date: Wed, 4 Oct 2023 20:52:59 -0700 Subject: [PATCH] Rewrites InputPercentTest with matchers Issue #2745 --- .../aaps/plugins/automation/elements/InputPercentTest.kt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/automation/src/test/kotlin/app/aaps/plugins/automation/elements/InputPercentTest.kt b/plugins/automation/src/test/kotlin/app/aaps/plugins/automation/elements/InputPercentTest.kt index b7a0941824..d8298f7daf 100644 --- a/plugins/automation/src/test/kotlin/app/aaps/plugins/automation/elements/InputPercentTest.kt +++ b/plugins/automation/src/test/kotlin/app/aaps/plugins/automation/elements/InputPercentTest.kt @@ -1,7 +1,7 @@ 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 InputPercentTest : TriggerTestBase() { @@ -9,6 +9,6 @@ class InputPercentTest : TriggerTestBase() { @Test fun setValueTest() { val i = InputPercent() i.value = 10.0 - Assertions.assertEquals(10.0, i.value, 0.01) + assertThat(i.value).isWithin(0.01).of(10.0) } -} \ No newline at end of file +}