fengdai
06/14/2022, 11:57 AMLaunchedEffect which will change a state after a delay and trigger a recomposition. I want to wait for the end of the consequent recomposition and then do some assertions. How can I achieve the waiting? waitForIdle doesn’t work.Albert Chang
06/14/2022, 1:26 PMrule.mainClock.advanceTimeBy()?fengdai
06/14/2022, 1:41 PMwaitUntil to wait for the state changing. And I known the recomposition happens after that. If I use advanceTimeBy after the waitUntil. What's the appropriate time for it, so I can reach the end of the recomposition?Albert Chang
06/14/2022, 2:01 PMwaitUntil / mainClock.advanceTimeUntil() should also work if you know the condition.