Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 623dadf0 authored by Steve Elliott's avatar Steve Elliott
Browse files

Remove illegal supertype

Under Kotlin 2, this is no longer valid.

Test: atest
Flag: EXEMPT test change
Change-Id: I70cd3d1e3d9e1281d28cb637565e0131d9b6abfe
parent de547b23
Loading
Loading
Loading
Loading
+4 −6
Original line number Diff line number Diff line
@@ -484,14 +484,12 @@ class RepeatWhenAttachedTest : SysuiTestCase() {
    private fun CoroutineScope.repeatWhenAttached(): DisposableHandle {
        return view.repeatWhenAttached(
            coroutineContext = coroutineContext,
            block = block,
            block = { block.invoke(this) },
        )
    }

    private class Block : suspend LifecycleOwner.(View) -> Unit {
        data class Invocation(
            val lifecycleOwner: LifecycleOwner,
        ) {
    private class Block {
        data class Invocation(val lifecycleOwner: LifecycleOwner) {
            val lifecycleState: Lifecycle.State
                get() = lifecycleOwner.lifecycle.currentState
        }
@@ -504,7 +502,7 @@ class RepeatWhenAttachedTest : SysuiTestCase() {
        val latestLifecycleState: Lifecycle.State
            get() = _invocations.last().lifecycleState

        override suspend fun invoke(lifecycleOwner: LifecycleOwner, view: View) {
        fun invoke(lifecycleOwner: LifecycleOwner) {
            _invocations.add(Invocation(lifecycleOwner))
        }
    }