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

Commit e5f6d6b0 authored by Treehugger Robot's avatar Treehugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Mock ActivityStateAsyncUpdater.startBatchSession()" into main

parents 9aa8e567 2e05f39e
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -657,8 +657,11 @@ public class SystemServicesTestRule implements TestRule {
            doReturn(true).when(intentFirewall).checkStartActivity(
                    any(), anyInt(), anyInt(), nullable(String.class), any());
            final ProcessStateController psc = mock(ProcessStateController.class);
            doReturn(mock(ProcessStateController.ActivityStateAsyncUpdater.class)).when(
                    psc).createActivityStateAsyncUpdater(any());
            final ProcessStateController.ActivityStateAsyncUpdater asau = mock(
                    ProcessStateController.ActivityStateAsyncUpdater.class);
            doReturn(mock(ProcessStateController.AsyncBatchSession.class)).when(
                    asau).startBatchSession();
            doReturn(asau).when(psc).createActivityStateAsyncUpdater(any());
            initialize(intentFirewall, null /* intentController */, psc,
                    DisplayThread.getHandler().getLooper());
            spyOn(getLifecycleManager());