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

Commit 3a1d7f97 authored by Hyundo Moon's avatar Hyundo Moon Committed by Android (Google) Code Review
Browse files

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

parents 8c312386 1f252200
Loading
Loading
Loading
Loading
+72 −61
Original line number Diff line number Diff line
@@ -240,7 +240,10 @@ public class BluetoothPbapSimVcardManagerTest {

    @Test
    public void testGetSIMPhonebookNameList_orderByIndexed() {
        String prevLocalPhoneName = BluetoothPbapService.getLocalPhoneName();
        try {
            final String localPhoneName = "test_local_phone_name";
            BluetoothPbapService.setLocalPhoneName(localPhoneName);
            Cursor cursor = initManager();
            List<String> nameList = Arrays.asList("D", "C", "A", "B");

@@ -270,10 +273,15 @@ public class BluetoothPbapSimVcardManagerTest {
            expectedResult.addAll(nameList);

            assertThat(result).isEqualTo(expectedResult);
        } finally {
            BluetoothPbapService.setLocalPhoneName(prevLocalPhoneName);
        }
    }

    @Test
    public void testGetSIMPhonebookNameList_orderByAlphabet() {
        String prevLocalPhoneName = BluetoothPbapService.getLocalPhoneName();
        try {
            final String localPhoneName = "test_local_phone_name";
            BluetoothPbapService.setLocalPhoneName(localPhoneName);
            Cursor cursor = initManager();
@@ -305,6 +313,9 @@ public class BluetoothPbapSimVcardManagerTest {
            expectedResult.add(0, localPhoneName);

            assertThat(result).isEqualTo(expectedResult);
        } finally {
            BluetoothPbapService.setLocalPhoneName(prevLocalPhoneName);
        }
    }

    @Test