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

Commit c5077ebc authored by Yara Hassan's avatar Yara Hassan
Browse files

Fix bluetooth test broken by Service change

http://ag/10468382 was rolledback because it broke bluetooth tests http://b/151715362.
Will cherrypick this change into our internal branch to roll-forward the service change.

Bug: 150451947
Test: Locally
Change-Id: Ib7a92697e8c57fd98514c54df98b510ac11f188e
parent fcfd6a1f
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -85,6 +85,7 @@ public class AdapterServiceTest {
    private @Mock IBluetoothCallback mIBluetoothCallback;
    private @Mock Binder mBinder;
    private @Mock AudioManager mAudioManager;
    private @Mock android.app.Application mApplication;

    private static final int CONTEXT_SWITCH_MS = 100;
    private static final int ONE_SECOND_MS = 1000;
@@ -159,7 +160,7 @@ public class AdapterServiceTest {
        when(mMockService2.getName()).thenReturn("Service2");

        // Attach a context to the service for permission checks.
        mAdapterService.attach(mMockContext, null, null, null, null, null);
        mAdapterService.attach(mMockContext, null, null, null, mApplication, null);

        mAdapterService.onCreate();
        mServiceBinder.registerCallback(mIBluetoothCallback);