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

Commit 46291017 authored by Sudheer Shanka's avatar Sudheer Shanka Committed by Android (Google) Code Review
Browse files

Merge "Slightly stagger the timing of broadcast dispatches." into main

parents 7965b175 2b440636
Loading
Loading
Loading
Loading
+3 −0
Original line number Original line Diff line number Diff line
@@ -1413,6 +1413,9 @@ public final class BroadcastQueueModernImplTest extends BaseBroadcastQueueTest {
        final BroadcastRecord userPresentRecord2 = makeBroadcastRecord(userPresent);
        final BroadcastRecord userPresentRecord2 = makeBroadcastRecord(userPresent);


        mImpl.enqueueBroadcastLocked(userPresentRecord1);
        mImpl.enqueueBroadcastLocked(userPresentRecord1);
        // Wait for a few ms before sending another broadcast to allow comparing the
        // enqueue timestamps of these broadcasts.
        SystemClock.sleep(5);
        mImpl.enqueueBroadcastLocked(userPresentRecord2);
        mImpl.enqueueBroadcastLocked(userPresentRecord2);


        final BroadcastProcessQueue queue = mImpl.getProcessQueue(PACKAGE_GREEN,
        final BroadcastProcessQueue queue = mImpl.getProcessQueue(PACKAGE_GREEN,