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

Commit f809338a authored by Charlie Boutier's avatar Charlie Boutier Committed by Automerger Merge Worker
Browse files

Merge changes from topic "avatar_classic_pairing" am: 7c4b40d5

parents d557ce9d 7c4b40d5
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -55,6 +55,7 @@ import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Objects;
import java.util.Set;
import java.util.function.Predicate;

@@ -988,9 +989,10 @@ final class RemoteDevices {
        BluetoothDevice device = getDevice(address);

        if (device == null) {
            errorLog("aclStateChangeCallback: device is NULL, address="
            warnLog("aclStateChangeCallback: device is NULL, address="
                    + Utils.getAddressStringFromByte(address) + ", newState=" + newState);
            return;
            addDeviceProperties(address);
            device = Objects.requireNonNull(getDevice(address));
        }

        DeviceProperties deviceProperties = getDeviceProperties(device);
@@ -1025,6 +1027,9 @@ final class RemoteDevices {
                intent.setPackage(mAdapterService.getString(R.string.pairing_ui_package));
                mAdapterService.sendBroadcast(intent, BLUETOOTH_CONNECT,
                        Utils.getTempAllowlistBroadcastOptions());
            } else if (device.getBondState() == BluetoothDevice.BOND_NONE) {
                String key = Utils.getAddressStringFromByte(address);
                mDevices.remove(key);
            }
            if (state == BluetoothAdapter.STATE_ON || state == BluetoothAdapter.STATE_TURNING_OFF) {
                intent = new Intent(BluetoothDevice.ACTION_ACL_DISCONNECTED);
+2 −0
Original line number Diff line number Diff line
@@ -30,6 +30,7 @@ import com.android.bluetooth.hfp.HeadsetHalConstants;
import org.junit.After;
import org.junit.Assert;
import org.junit.Before;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.ArgumentCaptor;
@@ -274,6 +275,7 @@ public class RemoteDevicesTest {
    }

    @Test
    @Ignore("b/266128644")
    public void testResetBatteryLevel_testAclStateChangeCallback() {
        int batteryLevel = 10;

+1 −1
Original line number Diff line number Diff line
@@ -62,7 +62,7 @@ class AVRCPProxy(ProfileProxy):

        """
        # Simulate CSR timeout: b/259102046
        time.sleep(2)
        time.sleep(4)
        self.connection = self.host.WaitConnection(address=pts_addr).connection
        if ("TG" in test and "TG/VLH" not in test) or "CT/VLH" in test:
            try:
+1 −1
Original line number Diff line number Diff line
@@ -207,7 +207,7 @@ class GAPProxy(ProfileProxy):

        self.host.StartAdvertising(
            own_address_type=OwnAddressType.PUBLIC,
            data=DataTypes(complete_service_class_uuids128=["955798ce-3022-455c-b759-ee8edcd73d1a"],))
            data=DataTypes(incomplete_service_class_uuids128=["955798ce-3022-455c-b759-ee8edcd73d1a"],))
        return "OK"

    @assert_description
+39 −19
Original line number Diff line number Diff line
@@ -110,23 +110,9 @@
    "AVRCP/TG/ICC/BV-02-I",
    "AVRCP/TG/INV/BI-01-C",
    "AVRCP/TG/INV/BI-02-C",
    "AVRCP/TG/MCN/CB/BI-01-C",
    "AVRCP/TG/MCN/CB/BI-03-C",
    "AVRCP/TG/MCN/CB/BI-04-C",
    "AVRCP/TG/MCN/CB/BI-05-C",
    "AVRCP/TG/MCN/CB/BV-02-C",
    "AVRCP/TG/MCN/CB/BV-02-I",
    "AVRCP/TG/MCN/CB/BV-03-I",
    "AVRCP/TG/MCN/CB/BV-05-C",
    "AVRCP/TG/MCN/CB/BV-06-C",
    "AVRCP/TG/MCN/CB/BV-06-I",
    "AVRCP/TG/MCN/CB/BV-08-C",
    "AVRCP/TG/MCN/NP/BV-02-C",
    "AVRCP/TG/MCN/NP/BV-06-C",
    "AVRCP/TG/MCN/NP/BV-07-C",
    "AVRCP/TG/MCN/NP/BV-09-C",
    "AVRCP/TG/MCN/NP/BV-04-I",
    "AVRCP/TG/MCN/NP/BV-05-I",
    "AVRCP/TG/MDI/BV-02-C",
    "AVRCP/TG/MDI/BV-04-C",
    "AVRCP/TG/MDI/BV-05-C",
@@ -135,8 +121,6 @@
    "AVRCP/TG/MPS/BV-02-C",
    "AVRCP/TG/MPS/BV-02-I",
    "AVRCP/TG/MPS/BV-03-I",
    "AVRCP/TG/MPS/BV-04-C",
    "AVRCP/TG/MPS/BV-06-C",
    "AVRCP/TG/MPS/BV-09-C",
    "AVRCP/TG/NFY/BI-01-C",
    "AVRCP/TG/NFY/BV-02-C",
@@ -180,8 +164,6 @@
    "GATT/CL/GAD/BV-04-C",
    "GATT/CL/GAD/BV-05-C",
    "GATT/CL/GAD/BV-06-C",
    "GATT/CL/GAD/BV-07-C",
    "GATT/CL/GAD/BV-08-C",
    "GATT/CL/GAR/BI-01-C",
    "GATT/CL/GAR/BI-02-C",
    "GATT/CL/GAR/BI-06-C",
@@ -544,7 +526,26 @@
  ],
  "flaky": [
    "A2DP/SRC/SUS/BV-02-I",
    "AVRCP/TG/RCR/BV-02-C"
    "AVRCP/TG/RCR/BV-02-C",
    "AVRCP/TG/MCN/CB/BI-01-C",
    "AVRCP/TG/MCN/CB/BV-02-I",
    "AVRCP/TG/MCN/CB/BI-03-C",
    "AVRCP/TG/MCN/CB/BI-04-C",
    "AVRCP/TG/MCN/CB/BI-05-C",
    "AVRCP/TG/MCN/CB/BV-02-C",
    "AVRCP/TG/MCN/CB/BV-03-I",
    "AVRCP/TG/MCN/CB/BV-05-C",
    "AVRCP/TG/MCN/CB/BV-06-I",
    "AVRCP/TG/MCN/CB/BV-08-C",
    "AVRCP/TG/MCN/NP/BV-02-C",
    "AVRCP/TG/MCN/NP/BV-04-I",
    "AVRCP/TG/MCN/NP/BV-05-I",
    "AVRCP/TG/MCN/NP/BV-06-C",
    "AVRCP/TG/MCN/NP/BV-09-C",
    "AVRCP/TG/MPS/BV-04-C",
    "AVRCP/TG/MPS/BV-06-C",
    "GATT/CL/GAD/BV-07-C",
    "GATT/CL/GAD/BV-08-C"
  ],
  "skip": [
    "A2DP/SNK/SDP/BV-02-I",
@@ -593,13 +594,30 @@
    "AVRCP/CT/CRC/BV-01-I",
    "AVRCP/CT/PTH/BV-01-C",
    "AVRCP/CT/PTT/BV-01-I",
    "AVRCP/TG/MCN/CB/BI-01-C",
    "AVRCP/TG/MCN/CB/BI-02-C",
    "AVRCP/TG/MCN/CB/BI-03-C",
    "AVRCP/TG/MCN/CB/BI-04-C",
    "AVRCP/TG/MCN/CB/BI-05-C",
    "AVRCP/TG/MCN/CB/BV-01-I",
    "AVRCP/TG/MCN/CB/BV-02-C",
    "AVRCP/TG/MCN/CB/BV-02-I",
    "AVRCP/TG/MCN/CB/BV-04-I",
    "AVRCP/TG/MCN/CB/BV-03-I",
    "AVRCP/TG/MCN/CB/BV-05-C",
    "AVRCP/TG/MCN/CB/BV-06-I",
    "AVRCP/TG/MCN/CB/BV-08-C",
    "AVRCP/TG/MCN/CB/BV-09-C",
    "AVRCP/TG/MCN/NP/BI-01-C",
    "AVRCP/TG/MCN/NP/BV-01-I",
    "AVRCP/TG/MCN/NP/BV-02-C",
    "AVRCP/TG/MCN/NP/BV-04-I",
    "AVRCP/TG/MCN/NP/BV-05-I",
    "AVRCP/TG/MCN/NP/BV-09-C",
    "AVRCP/TG/MCN/NP/BV-06-I",
    "AVRCP/TG/MCN/NP/BV-06-C",
    "AVRCP/TG/MPS/BV-04-C",
    "AVRCP/TG/MPS/BV-06-C",
    "AVRCP/TG/MPS/BV-01-I",
    "AVRCP/TG/NFY/BV-04-C",
    "AVRCP/TG/NFY/BV-06-C",
@@ -685,6 +703,8 @@
    "GAP/SEC/SEM/BV-42-C",
    "GAP/SEC/SEM/BV-43-C",
    "GAP/SEC/SEM/BV-44-C",
    "GATT/CL/GAD/BV-07-C",
    "GATT/CL/GAD/BV-08-C",
    "GATT/CL/GAI/BV-01-C",
    "GATT/CL/GAN/BV-01-C",
    "GATT/CL/GAN/BV-02-C",
Loading