From c292aedd62c292a1a7636df32c80b8a8958c0233 Mon Sep 17 00:00:00 2001 From: Alyssa Date: Sat, 17 Aug 2024 16:18:27 +0100 Subject: [PATCH] fix integration test --- client/src/test/kotlin/util/UpdateManagerTest.kt | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/client/src/test/kotlin/util/UpdateManagerTest.kt b/client/src/test/kotlin/util/UpdateManagerTest.kt index d0d9de7..333cfd4 100644 --- a/client/src/test/kotlin/util/UpdateManagerTest.kt +++ b/client/src/test/kotlin/util/UpdateManagerTest.kt @@ -8,6 +8,7 @@ import com.github.alyssaburlton.swingtest.findWindow import com.github.alyssaburlton.swingtest.flushEdt import com.github.alyssaburlton.swingtest.getChild import com.github.alyssaburlton.swingtest.shouldNotBeVisible +import io.kotest.matchers.ints.shouldBeGreaterThan import io.kotest.matchers.shouldBe import io.kotest.matchers.shouldNotBe import io.kotest.matchers.string.shouldContain @@ -97,13 +98,7 @@ class UpdateManagerTest : AbstractTest() { val version = responseJson.getString("tag_name") version.shouldStartWith("v") - responseJson.getJSONArray("assets").length() shouldBe 1 - - val asset = responseJson.getJSONArray("assets").getJSONObject(0) - asset.getLong("id") shouldNotBe null - asset.getString("name") shouldStartWith "Dartzee" - asset.getString("name") shouldEndWith ".jar" - asset.getLong("size") shouldNotBe null + responseJson.getJSONArray("assets").length() shouldBeGreaterThan 0 } /** Parsing */