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

Commit 743012c4 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Update ASHA profile sysprop API name to be in line with other profiles"...

Merge "Update ASHA profile sysprop API name to be in line with other profiles" am: 752adb8d am: 07d4b9e7

Original change: https://android-review.googlesource.com/c/platform/packages/modules/Bluetooth/+/1960680

Change-Id: I1860d744459191750f875ac089725004c3ff8580
parents 337a549e 07d4b9e7
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -157,7 +157,7 @@ public class Config {
            boolean supported = false;
            if (config.mClass == HearingAidService.class) {
                supported =
                        BluetoothProperties.audioStreamingForHearingAidSupported().orElse(false);
                        BluetoothProperties.isProfileAshaCentralEnabled().orElse(false);
            } else {
                supported = resources.getBoolean(config.mSupported);
            }
+4 −4
Original line number Diff line number Diff line
@@ -220,7 +220,7 @@ public class ActiveDeviceManagerTest {
    @Test
    public void hearingAidActive_clearA2dpAndHeadsetActive() {
        Assume.assumeTrue("Ignore test when HearingAidService is not enabled",
                BluetoothProperties.audioStreamingForHearingAidSupported().orElse(false));
                BluetoothProperties.isProfileAshaCentralEnabled().orElse(false));

        a2dpConnected(mA2dpHeadsetDevice);
        headsetConnected(mA2dpHeadsetDevice);
@@ -238,7 +238,7 @@ public class ActiveDeviceManagerTest {
    @Test
    public void hearingAidActive_dontSetA2dpAndHeadsetActive() {
        Assume.assumeTrue("Ignore test when HearingAidService is not enabled",
                BluetoothProperties.audioStreamingForHearingAidSupported().orElse(false));
                BluetoothProperties.isProfileAshaCentralEnabled().orElse(false));

        hearingAidActiveDeviceChanged(mHearingAidDevice);
        a2dpConnected(mA2dpHeadsetDevice);
@@ -255,7 +255,7 @@ public class ActiveDeviceManagerTest {
    @Test
    public void hearingAidActive_setA2dpActiveExplicitly() {
        Assume.assumeTrue("Ignore test when HearingAidService is not enabled",
                BluetoothProperties.audioStreamingForHearingAidSupported().orElse(false));
                BluetoothProperties.isProfileAshaCentralEnabled().orElse(false));

        hearingAidActiveDeviceChanged(mHearingAidDevice);
        a2dpConnected(mA2dpHeadsetDevice);
@@ -275,7 +275,7 @@ public class ActiveDeviceManagerTest {
    @Test
    public void hearingAidActive_setHeadsetActiveExplicitly() {
        Assume.assumeTrue("Ignore test when HearingAidService is not enabled",
                BluetoothProperties.audioStreamingForHearingAidSupported().orElse(false));
                BluetoothProperties.isProfileAshaCentralEnabled().orElse(false));

        hearingAidActiveDeviceChanged(mHearingAidDevice);
        headsetConnected(mA2dpHeadsetDevice);
+1 −1
Original line number Diff line number Diff line
@@ -119,7 +119,7 @@ public class AdapterServiceTest {
            Process.myUid()).build();

    private final boolean hearingAidSupported =
            BluetoothProperties.audioStreamingForHearingAidSupported().orElse(false);
            BluetoothProperties.isProfileAshaCentralEnabled().orElse(false);

    private PowerManager mPowerManager;
    private PermissionCheckerManager mPermissionCheckerManager;
+2 −2
Original line number Diff line number Diff line
@@ -84,7 +84,7 @@ public class HearingAidServiceTest {
    public void setUp() throws Exception {
        mTargetContext = InstrumentationRegistry.getTargetContext();
        Assume.assumeTrue("Ignore test when HearingAidService is not enabled",
                BluetoothProperties.audioStreamingForHearingAidSupported().orElse(false));
                BluetoothProperties.isProfileAshaCentralEnabled().orElse(false));
        // Set up mocks and test assets
        MockitoAnnotations.initMocks(this);

@@ -127,7 +127,7 @@ public class HearingAidServiceTest {

    @After
    public void tearDown() throws Exception {
        if (!BluetoothProperties.audioStreamingForHearingAidSupported().orElse(false)) {
        if (!BluetoothProperties.isProfileAshaCentralEnabled().orElse(false)) {
            return;
        }
        stopService();
+2 −2
Original line number Diff line number Diff line
@@ -64,7 +64,7 @@ public class HearingAidStateMachineTest {
    public void setUp() throws Exception {
        mTargetContext = InstrumentationRegistry.getTargetContext();
        Assume.assumeTrue("Ignore test when HearingAidService is not enabled",
                BluetoothProperties.audioStreamingForHearingAidSupported().orElse(false));
                BluetoothProperties.isProfileAshaCentralEnabled().orElse(false));
        // Set up mocks and test assets
        MockitoAnnotations.initMocks(this);
        TestUtils.setAdapterService(mAdapterService);
@@ -86,7 +86,7 @@ public class HearingAidStateMachineTest {

    @After
    public void tearDown() throws Exception {
        if (!BluetoothProperties.audioStreamingForHearingAidSupported().orElse(false)) {
        if (!BluetoothProperties.isProfileAshaCentralEnabled().orElse(false)) {
            return;
        }
        mHearingAidStateMachine.doQuit();
Loading