WebLaunchLinkTest.kt
composeApp/src/wasmJsTest/kotlin/eu/friedcutlet/yokan/app/WebLaunchLinkTest.kt
1package eu.friedcutlet.yokan.app23import eu.friedcutlet.yokan.ui.navigation.searchDeepLink4import kotlin.test.Test5import kotlin.test.assertEquals6import kotlin.test.assertNull78class WebLaunchLinkTest {9 @Test10 fun mapsSearchAndLinkQueryParameters() {11 assertEquals(searchDeepLink("One Piece"), webLaunchLink("?search=One+Piece"))12 assertEquals(13 "animetail://add-repo?url=https://example.com/index.min.json",14 webLaunchLink("?link=animetail%3A%2F%2Fadd-repo%3Furl%3Dhttps%3A%2F%2Fexample.com%2Findex.min.json"),15 )16 assertNull(webLaunchLink("?search=%20"))17 assertNull(webLaunchLink(""))18 }19}20