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

Commit 2ae5f488 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Fix failing tests" into tm-qpr-dev

parents 6206f57b 50520b0e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -578,7 +578,7 @@ public class ActiveDeviceManagerTest {
                }
        );
        a2dpDisconnected(mA2dpDevice);
        verify(mA2dpService, timeout(TIMEOUT_MS)).setActiveDevice(isNull());
        verify(mA2dpService, timeout(TIMEOUT_MS).atLeast(1)).setActiveDevice(isNull());
        verify(mHearingAidService, timeout(TIMEOUT_MS).times(2))
                .setActiveDevice(mHearingAidDevice);
    }
+5 −0
Original line number Diff line number Diff line
@@ -180,6 +180,11 @@ public class HearingAidServiceTest {
        Assert.assertEquals(newState, intent.getIntExtra(BluetoothProfile.EXTRA_STATE, -1));
        Assert.assertEquals(prevState, intent.getIntExtra(BluetoothProfile.EXTRA_PREVIOUS_STATE,
                -1));
        if (newState == BluetoothProfile.STATE_CONNECTED) {
            // ActiveDeviceManager calls setActiveDevice when connected.
            mService.setActiveDevice(device);
        }

    }

    private void verifyNoConnectionStateIntent(int timeoutMs, BluetoothDevice device) {