From ba298757bfcae5815dd7504d3497d55de5624fe9 Mon Sep 17 00:00:00 2001 From: Jake Wharton Date: Tue, 9 Apr 2024 21:49:08 -0400 Subject: [PATCH] Delete generated typealiases for migration (#1943) 0.10.0 was released. These won't be in 0.11.0. --- CHANGELOG.md | 1 + .../api/redwood-layout-testing.api | 5 -- .../api/redwood-layout-testing.klib.api | 1 - .../api/redwood-lazylayout-testing.api | 5 -- .../api/redwood-lazylayout-testing.klib.api | 1 - .../redwood/testing/ViewRecyclingTester.kt | 2 +- .../cash/redwood/tooling/codegen/codegen.kt | 1 - .../tooling/codegen/protocolCodegen.kt | 2 - .../codegen/protocolGuestGeneration.kt | 19 ------- .../tooling/codegen/protocolHostGeneration.kt | 22 -------- .../tooling/codegen/testingGeneration.kt | 54 ------------------- .../redwood/counter/presenter/CounterTest.kt | 6 +-- .../android/composeui/EmojiSearchActivity.kt | 2 +- .../android/views/EmojiSearchActivity.kt | 2 +- .../redwood/emojisearch/ios/exposed.kt | 2 +- .../treehouse/RealEmojiSearchPresenter.kt | 2 +- .../emojisearch/presenter/EmojiSearchTest.kt | 8 +-- 17 files changed, 13 insertions(+), 122 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6b7ffeec11..c5519ef8f6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ New: - Nothing yet! Changed: +- Removed generated `typealias`es for package names which changed in 0.10.0. - In `UIViewLazyList`'s `UITableView`, adding special-case handling for programmatic scroll-to-top calls. Fixed: diff --git a/redwood-layout-testing/api/redwood-layout-testing.api b/redwood-layout-testing/api/redwood-layout-testing.api index a2676cbfc3..af03363ef1 100644 --- a/redwood-layout-testing/api/redwood-layout-testing.api +++ b/redwood-layout-testing/api/redwood-layout-testing.api @@ -77,8 +77,3 @@ public final class app/cash/redwood/layout/testing/SpacerValue : app/cash/redwoo public fun toWidget (Lapp/cash/redwood/widget/WidgetSystem;)Lapp/cash/redwood/widget/Widget; } -public final class app/cash/redwood/layout/widget/TestingDeprecatedKt { - public static final fun RedwoodLayoutTester (Lapp/cash/redwood/ui/OnBackPressedDispatcher;Lapp/cash/redwood/testing/TestSavedState;Lapp/cash/redwood/ui/UiConfiguration;Lkotlin/jvm/functions/Function2;Lkotlin/coroutines/Continuation;)Ljava/lang/Object; - public static synthetic fun RedwoodLayoutTester$default (Lapp/cash/redwood/ui/OnBackPressedDispatcher;Lapp/cash/redwood/testing/TestSavedState;Lapp/cash/redwood/ui/UiConfiguration;Lkotlin/jvm/functions/Function2;Lkotlin/coroutines/Continuation;ILjava/lang/Object;)Ljava/lang/Object; -} - diff --git a/redwood-layout-testing/api/redwood-layout-testing.klib.api b/redwood-layout-testing/api/redwood-layout-testing.klib.api index 279265aae9..39a85df4ff 100644 --- a/redwood-layout-testing/api/redwood-layout-testing.klib.api +++ b/redwood-layout-testing/api/redwood-layout-testing.klib.api @@ -102,4 +102,3 @@ final class app.cash.redwood.layout.testing/SpacerValue : app.cash.redwood.testi final fun (): app.cash.redwood.ui/Dp // app.cash.redwood.layout.testing/SpacerValue.width.|(){}[0] } final suspend fun <#A: kotlin/Any?> app.cash.redwood.layout.testing/RedwoodLayoutTester(app.cash.redwood.ui/OnBackPressedDispatcher =..., app.cash.redwood.testing/TestSavedState? =..., app.cash.redwood.ui/UiConfiguration =..., kotlin.coroutines/SuspendFunction1>, #A>): #A // app.cash.redwood.layout.testing/RedwoodLayoutTester|RedwoodLayoutTester(app.cash.redwood.ui.OnBackPressedDispatcher;app.cash.redwood.testing.TestSavedState?;app.cash.redwood.ui.UiConfiguration;kotlin.coroutines.SuspendFunction1>,0:0>){0§}[0] -final suspend fun <#A: kotlin/Any?> app.cash.redwood.layout.widget/RedwoodLayoutTester(app.cash.redwood.ui/OnBackPressedDispatcher =..., app.cash.redwood.testing/TestSavedState? =..., app.cash.redwood.ui/UiConfiguration =..., kotlin.coroutines/SuspendFunction1>, #A>): #A // app.cash.redwood.layout.widget/RedwoodLayoutTester|RedwoodLayoutTester(app.cash.redwood.ui.OnBackPressedDispatcher;app.cash.redwood.testing.TestSavedState?;app.cash.redwood.ui.UiConfiguration;kotlin.coroutines.SuspendFunction1>,0:0>){0§}[0] diff --git a/redwood-lazylayout-testing/api/redwood-lazylayout-testing.api b/redwood-lazylayout-testing/api/redwood-lazylayout-testing.api index d6be25384a..4bbffded4e 100644 --- a/redwood-lazylayout-testing/api/redwood-lazylayout-testing.api +++ b/redwood-lazylayout-testing/api/redwood-lazylayout-testing.api @@ -56,8 +56,3 @@ public final class app/cash/redwood/lazylayout/testing/RefreshableLazyListValue public fun toWidget (Lapp/cash/redwood/widget/WidgetSystem;)Lapp/cash/redwood/widget/Widget; } -public final class app/cash/redwood/lazylayout/widget/TestingDeprecatedKt { - public static final fun RedwoodLazyLayoutTester (Lapp/cash/redwood/ui/OnBackPressedDispatcher;Lapp/cash/redwood/testing/TestSavedState;Lapp/cash/redwood/ui/UiConfiguration;Lkotlin/jvm/functions/Function2;Lkotlin/coroutines/Continuation;)Ljava/lang/Object; - public static synthetic fun RedwoodLazyLayoutTester$default (Lapp/cash/redwood/ui/OnBackPressedDispatcher;Lapp/cash/redwood/testing/TestSavedState;Lapp/cash/redwood/ui/UiConfiguration;Lkotlin/jvm/functions/Function2;Lkotlin/coroutines/Continuation;ILjava/lang/Object;)Ljava/lang/Object; -} - diff --git a/redwood-lazylayout-testing/api/redwood-lazylayout-testing.klib.api b/redwood-lazylayout-testing/api/redwood-lazylayout-testing.klib.api index a664bc04c2..10acad50e3 100644 --- a/redwood-lazylayout-testing/api/redwood-lazylayout-testing.klib.api +++ b/redwood-lazylayout-testing/api/redwood-lazylayout-testing.klib.api @@ -84,4 +84,3 @@ final class app.cash.redwood.lazylayout.testing/RefreshableLazyListValue : app.c final fun (): app.cash.redwood.layout.api/Constraint // app.cash.redwood.lazylayout.testing/RefreshableLazyListValue.width.|(){}[0] } final suspend fun <#A: kotlin/Any?> app.cash.redwood.lazylayout.testing/RedwoodLazyLayoutTester(app.cash.redwood.ui/OnBackPressedDispatcher =..., app.cash.redwood.testing/TestSavedState? =..., app.cash.redwood.ui/UiConfiguration =..., kotlin.coroutines/SuspendFunction1>, #A>): #A // app.cash.redwood.lazylayout.testing/RedwoodLazyLayoutTester|RedwoodLazyLayoutTester(app.cash.redwood.ui.OnBackPressedDispatcher;app.cash.redwood.testing.TestSavedState?;app.cash.redwood.ui.UiConfiguration;kotlin.coroutines.SuspendFunction1>,0:0>){0§}[0] -final suspend fun <#A: kotlin/Any?> app.cash.redwood.lazylayout.widget/RedwoodLazyLayoutTester(app.cash.redwood.ui/OnBackPressedDispatcher =..., app.cash.redwood.testing/TestSavedState? =..., app.cash.redwood.ui/UiConfiguration =..., kotlin.coroutines/SuspendFunction1>, #A>): #A // app.cash.redwood.lazylayout.widget/RedwoodLazyLayoutTester|RedwoodLazyLayoutTester(app.cash.redwood.ui.OnBackPressedDispatcher;app.cash.redwood.testing.TestSavedState?;app.cash.redwood.ui.UiConfiguration;kotlin.coroutines.SuspendFunction1>,0:0>){0§}[0] diff --git a/redwood-testing/src/commonTest/kotlin/app/cash/redwood/testing/ViewRecyclingTester.kt b/redwood-testing/src/commonTest/kotlin/app/cash/redwood/testing/ViewRecyclingTester.kt index 4d29426d4b..11e0c8ce2a 100644 --- a/redwood-testing/src/commonTest/kotlin/app/cash/redwood/testing/ViewRecyclingTester.kt +++ b/redwood-testing/src/commonTest/kotlin/app/cash/redwood/testing/ViewRecyclingTester.kt @@ -33,8 +33,8 @@ import assertk.assertions.isEmpty import assertk.assertions.isEqualTo import com.example.redwood.testing.protocol.guest.TestSchemaProtocolBridge import com.example.redwood.testing.protocol.host.TestSchemaProtocolFactory +import com.example.redwood.testing.testing.TestSchemaTester import com.example.redwood.testing.testing.TestSchemaTestingWidgetFactory -import com.example.redwood.testing.widget.TestSchemaTester import com.example.redwood.testing.widget.TestSchemaWidgetSystem import kotlinx.coroutines.CoroutineScope import kotlinx.coroutines.coroutineScope diff --git a/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/codegen.kt b/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/codegen.kt index fd273d4bfc..79beb6ed42 100644 --- a/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/codegen.kt +++ b/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/codegen.kt @@ -57,7 +57,6 @@ internal fun SchemaSet.generateFileSpecs(type: CodegenType): List { } Testing -> { - add(testingDeprecations(schema)) add(generateTester(this@generateFileSpecs)) add(generateMutableWidgetFactory(schema)) for (widget in schema.widgets) { diff --git a/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolCodegen.kt b/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolCodegen.kt index 8572364626..25ec71634b 100644 --- a/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolCodegen.kt +++ b/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolCodegen.kt @@ -36,7 +36,6 @@ internal fun ProtocolSchemaSet.generateFileSpecs(type: ProtocolCodegenType): Lis return buildList { when (type) { Guest -> { - add(protocolGuestDeprecations(schema)) add(generateProtocolBridge(this@generateFileSpecs)) add(generateComposeProtocolModifierSerialization(this@generateFileSpecs)) for (dependency in all) { @@ -49,7 +48,6 @@ internal fun ProtocolSchemaSet.generateFileSpecs(type: ProtocolCodegenType): Lis } Host -> { - add(protocolHostDeprecations(schema)) add(generateProtocolFactory(this@generateFileSpecs)) for (dependency in all) { generateProtocolModifierImpls(dependency, host = schema)?.let { add(it) } diff --git a/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolGuestGeneration.kt b/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolGuestGeneration.kt index 3c2c506209..092a5d9128 100644 --- a/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolGuestGeneration.kt +++ b/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolGuestGeneration.kt @@ -47,7 +47,6 @@ import com.squareup.kotlinpoet.ParameterizedTypeName.Companion.parameterizedBy import com.squareup.kotlinpoet.PropertySpec import com.squareup.kotlinpoet.SHORT import com.squareup.kotlinpoet.STRING -import com.squareup.kotlinpoet.TypeAliasSpec import com.squareup.kotlinpoet.TypeName import com.squareup.kotlinpoet.TypeSpec import com.squareup.kotlinpoet.UNIT @@ -55,24 +54,6 @@ import com.squareup.kotlinpoet.joinToCode private val protocolViewType = UNIT -// TODO Delete this once 0.10.0 is released. -internal fun protocolGuestDeprecations(schema: Schema): FileSpec { - val typeName = "${schema.type.flatName}ProtocolBridge" - val newType = ClassName(schema.guestProtocolPackage(), typeName) - return FileSpec.builder(schema.composePackage(), "protocolGuestDeprecated") - .addAnnotation(suppressDeprecations) - .addTypeAlias( - TypeAliasSpec.builder(typeName, newType) - .addAnnotation( - AnnotationSpec.builder(Deprecated::class) - .addMember("%S", "Change import to .protocol.guest.$typeName") - .build(), - ) - .build(), - ) - .build() -} - /* class ExampleProtocolBridge private constructor( private val state: ProtocolState, diff --git a/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolHostGeneration.kt b/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolHostGeneration.kt index 08c4c1bb4e..d8603a631d 100644 --- a/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolHostGeneration.kt +++ b/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/protocolHostGeneration.kt @@ -41,34 +41,12 @@ import com.squareup.kotlinpoet.MemberName import com.squareup.kotlinpoet.ParameterSpec import com.squareup.kotlinpoet.ParameterizedTypeName.Companion.parameterizedBy import com.squareup.kotlinpoet.PropertySpec -import com.squareup.kotlinpoet.TypeAliasSpec import com.squareup.kotlinpoet.TypeName import com.squareup.kotlinpoet.TypeSpec -import com.squareup.kotlinpoet.TypeVariableName import com.squareup.kotlinpoet.UNIT import com.squareup.kotlinpoet.buildCodeBlock import com.squareup.kotlinpoet.joinToCode -// TODO Delete this once 0.10.0 is released. -internal fun protocolHostDeprecations(schema: Schema): FileSpec { - val typeName = "${schema.type.flatName}ProtocolFactory" - val newType = ClassName(schema.hostProtocolPackage(), typeName) - val unboundW = TypeVariableName("V") - return FileSpec.builder(schema.widgetPackage(), "protocolHostDeprecated") - .addAnnotation(suppressDeprecations) - .addTypeAlias( - TypeAliasSpec.builder(typeName, newType.parameterizedBy(unboundW)) - .addTypeVariable(unboundW) - .addAnnotation( - AnnotationSpec.builder(Deprecated::class) - .addMember("%S", "Change import to .protocol.host.$typeName") - .build(), - ) - .build(), - ) - .build() -} - /* @ObjCName("ExampleProtocolFactory", exact = true) public class ExampleProtocolFactory( diff --git a/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/testingGeneration.kt b/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/testingGeneration.kt index 44afbddbda..fe3a540678 100644 --- a/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/testingGeneration.kt +++ b/redwood-tooling-codegen/src/main/kotlin/app/cash/redwood/tooling/codegen/testingGeneration.kt @@ -23,7 +23,6 @@ import app.cash.redwood.tooling.schema.Widget.Children import app.cash.redwood.tooling.schema.Widget.Event import app.cash.redwood.tooling.schema.Widget.Property import com.squareup.kotlinpoet.ANY -import com.squareup.kotlinpoet.AnnotationSpec import com.squareup.kotlinpoet.BOOLEAN import com.squareup.kotlinpoet.ClassName import com.squareup.kotlinpoet.CodeBlock @@ -39,64 +38,11 @@ import com.squareup.kotlinpoet.MemberName import com.squareup.kotlinpoet.ParameterSpec import com.squareup.kotlinpoet.ParameterizedTypeName.Companion.parameterizedBy import com.squareup.kotlinpoet.PropertySpec -import com.squareup.kotlinpoet.TypeAliasSpec import com.squareup.kotlinpoet.TypeName import com.squareup.kotlinpoet.TypeSpec import com.squareup.kotlinpoet.TypeVariableName import com.squareup.kotlinpoet.joinToCode -// TODO Delete this once 0.10.0 is released. -internal fun testingDeprecations(schema: Schema): FileSpec { - val typeVarR = TypeVariableName("R") - val testingFunctionBodyType = LambdaTypeName.get( - receiver = RedwoodTesting.TestRedwoodComposition - .parameterizedBy(LIST.parameterizedBy(RedwoodTesting.WidgetValue)), - returnType = typeVarR, - ).copy(suspending = true) - val testingFunctionName = "${schema.type.flatName}Tester" - val deprecation = AnnotationSpec.builder(Deprecated::class) - .addMember("%S", "Change import to .testing.$testingFunctionName") - .build() - return FileSpec.builder(schema.widgetPackage(), "testingDeprecated") - .addAnnotation(suppressDeprecations) - .addFunction( - FunSpec.builder(testingFunctionName) - .addAnnotation(deprecation) - .addModifiers(SUSPEND) - .addParameter( - ParameterSpec.builder("onBackPressedDispatcher", Redwood.OnBackPressedDispatcher) - .defaultValue("%T", RedwoodTesting.NoOpOnBackPressedDispatcher) - .build(), - ) - .addParameter( - ParameterSpec.builder("savedState", RedwoodTesting.TestSavedState.copy(nullable = true)) - .defaultValue("null") - .build(), - ) - .addParameter( - ParameterSpec.builder("uiConfiguration", Redwood.UiConfiguration) - .defaultValue("%T()", Redwood.UiConfiguration) - .build(), - ) - .addParameter("body", testingFunctionBodyType) - .addTypeVariable(typeVarR) - .returns(typeVarR) - .addStatement("return %M(onBackPressedDispatcher, savedState, uiConfiguration, body)", MemberName(schema.testingPackage(), testingFunctionName)) - .build(), - ) - .apply { - for (widget in schema.widgets) { - val valueType = schema.widgetValueType(widget) - addTypeAlias( - TypeAliasSpec.builder(valueType.simpleName, valueType) - .addAnnotation(deprecation) - .build(), - ) - } - } - .build() -} - /* suspend fun ExampleTester( onBackPressedDispatcher: OnBackPressedDispatcher = NoOpOnBackPressedDispatcher, diff --git a/samples/counter/presenter/src/commonTest/kotlin/com/example/redwood/counter/presenter/CounterTest.kt b/samples/counter/presenter/src/commonTest/kotlin/com/example/redwood/counter/presenter/CounterTest.kt index c4467c7c05..15b45ca085 100644 --- a/samples/counter/presenter/src/commonTest/kotlin/com/example/redwood/counter/presenter/CounterTest.kt +++ b/samples/counter/presenter/src/commonTest/kotlin/com/example/redwood/counter/presenter/CounterTest.kt @@ -20,9 +20,9 @@ import app.cash.redwood.testing.WidgetValue import app.cash.redwood.testing.flatten import assertk.assertThat import assertk.assertions.isEqualTo -import com.example.redwood.counter.widget.ButtonValue -import com.example.redwood.counter.widget.SchemaTester -import com.example.redwood.counter.widget.TextValue +import com.example.redwood.counter.testing.ButtonValue +import com.example.redwood.counter.testing.SchemaTester +import com.example.redwood.counter.testing.TextValue import kotlin.test.Test import kotlinx.coroutines.test.runTest diff --git a/samples/emoji-search/android-composeui/src/main/kotlin/com/example/redwood/emojisearch/android/composeui/EmojiSearchActivity.kt b/samples/emoji-search/android-composeui/src/main/kotlin/com/example/redwood/emojisearch/android/composeui/EmojiSearchActivity.kt index 073c168944..3a6fcaabd7 100644 --- a/samples/emoji-search/android-composeui/src/main/kotlin/com/example/redwood/emojisearch/android/composeui/EmojiSearchActivity.kt +++ b/samples/emoji-search/android-composeui/src/main/kotlin/com/example/redwood/emojisearch/android/composeui/EmojiSearchActivity.kt @@ -50,8 +50,8 @@ import coil3.serviceLoaderEnabled import com.example.redwood.emojisearch.composeui.ComposeUiEmojiSearchWidgetFactory import com.example.redwood.emojisearch.composeui.EmojiSearchTheme import com.example.redwood.emojisearch.launcher.EmojiSearchAppSpec +import com.example.redwood.emojisearch.protocol.host.EmojiSearchProtocolFactory import com.example.redwood.emojisearch.treehouse.EmojiSearchPresenter -import com.example.redwood.emojisearch.widget.EmojiSearchProtocolFactory import com.example.redwood.emojisearch.widget.EmojiSearchWidgetSystem import kotlinx.coroutines.CoroutineScope import kotlinx.coroutines.Job diff --git a/samples/emoji-search/android-views/src/main/kotlin/com/example/redwood/emojisearch/android/views/EmojiSearchActivity.kt b/samples/emoji-search/android-views/src/main/kotlin/com/example/redwood/emojisearch/android/views/EmojiSearchActivity.kt index 0d6107293c..147776c044 100644 --- a/samples/emoji-search/android-views/src/main/kotlin/com/example/redwood/emojisearch/android/views/EmojiSearchActivity.kt +++ b/samples/emoji-search/android-views/src/main/kotlin/com/example/redwood/emojisearch/android/views/EmojiSearchActivity.kt @@ -39,9 +39,9 @@ import app.cash.zipline.loader.ManifestVerifier import app.cash.zipline.loader.asZiplineHttpClient import app.cash.zipline.loader.withDevelopmentServerPush import com.example.redwood.emojisearch.launcher.EmojiSearchAppSpec +import com.example.redwood.emojisearch.protocol.host.EmojiSearchProtocolFactory import com.example.redwood.emojisearch.treehouse.EmojiSearchPresenter import com.example.redwood.emojisearch.treehouse.emojiSearchSerializersModule -import com.example.redwood.emojisearch.widget.EmojiSearchProtocolFactory import com.example.redwood.emojisearch.widget.EmojiSearchWidgetSystem import com.google.android.material.snackbar.Snackbar import com.google.android.material.snackbar.Snackbar.LENGTH_INDEFINITE diff --git a/samples/emoji-search/ios-shared/src/commonMain/kotlin/com/example/redwood/emojisearch/ios/exposed.kt b/samples/emoji-search/ios-shared/src/commonMain/kotlin/com/example/redwood/emojisearch/ios/exposed.kt index bae5015cd8..7697082af6 100644 --- a/samples/emoji-search/ios-shared/src/commonMain/kotlin/com/example/redwood/emojisearch/ios/exposed.kt +++ b/samples/emoji-search/ios-shared/src/commonMain/kotlin/com/example/redwood/emojisearch/ios/exposed.kt @@ -26,7 +26,7 @@ import app.cash.redwood.treehouse.TreehouseUIView import app.cash.redwood.treehouse.TreehouseView import app.cash.redwood.treehouse.TreehouseView.WidgetSystem import app.cash.redwood.treehouse.bindWhenReady -import com.example.redwood.emojisearch.widget.EmojiSearchProtocolFactory +import com.example.redwood.emojisearch.protocol.host.EmojiSearchProtocolFactory import com.example.redwood.emojisearch.widget.EmojiSearchWidgetFactory import com.example.redwood.emojisearch.widget.EmojiSearchWidgetSystem import okio.ByteString diff --git a/samples/emoji-search/presenter-treehouse/src/jsMain/kotlin/com/example/redwood/emojisearch/treehouse/RealEmojiSearchPresenter.kt b/samples/emoji-search/presenter-treehouse/src/jsMain/kotlin/com/example/redwood/emojisearch/treehouse/RealEmojiSearchPresenter.kt index 0117ab76d7..ae45a14ccc 100644 --- a/samples/emoji-search/presenter-treehouse/src/jsMain/kotlin/com/example/redwood/emojisearch/treehouse/RealEmojiSearchPresenter.kt +++ b/samples/emoji-search/presenter-treehouse/src/jsMain/kotlin/com/example/redwood/emojisearch/treehouse/RealEmojiSearchPresenter.kt @@ -18,9 +18,9 @@ package com.example.redwood.emojisearch.treehouse import app.cash.redwood.treehouse.StandardAppLifecycle import app.cash.redwood.treehouse.ZiplineTreehouseUi import app.cash.redwood.treehouse.asZiplineTreehouseUi -import com.example.redwood.emojisearch.compose.EmojiSearchProtocolBridge import com.example.redwood.emojisearch.presenter.EmojiSearchTreehouseUi import com.example.redwood.emojisearch.presenter.Navigator +import com.example.redwood.emojisearch.protocol.guest.EmojiSearchProtocolBridge import kotlinx.serialization.json.Json class RealEmojiSearchPresenter( diff --git a/samples/emoji-search/presenter/src/commonTest/kotlin/com/example/redwood/emojisearch/presenter/EmojiSearchTest.kt b/samples/emoji-search/presenter/src/commonTest/kotlin/com/example/redwood/emojisearch/presenter/EmojiSearchTest.kt index c8e297b80d..3170f17444 100644 --- a/samples/emoji-search/presenter/src/commonTest/kotlin/com/example/redwood/emojisearch/presenter/EmojiSearchTest.kt +++ b/samples/emoji-search/presenter/src/commonTest/kotlin/com/example/redwood/emojisearch/presenter/EmojiSearchTest.kt @@ -21,15 +21,15 @@ import androidx.compose.runtime.mutableStateOf import androidx.compose.runtime.remember import androidx.compose.runtime.setValue import app.cash.redwood.layout.compose.Column -import app.cash.redwood.layout.widget.ColumnValue +import app.cash.redwood.layout.testing.ColumnValue import app.cash.redwood.testing.flatten import assertk.assertThat import assertk.assertions.containsExactly import com.example.redwood.emojisearch.compose.Text import com.example.redwood.emojisearch.compose.TextInput -import com.example.redwood.emojisearch.widget.EmojiSearchTester -import com.example.redwood.emojisearch.widget.TextInputValue -import com.example.redwood.emojisearch.widget.TextValue +import com.example.redwood.emojisearch.testing.EmojiSearchTester +import com.example.redwood.emojisearch.testing.TextInputValue +import com.example.redwood.emojisearch.testing.TextValue import example.values.TextFieldState import kotlin.test.Test import kotlinx.coroutines.test.runTest