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

Commit ad1969b0 authored by Hyundo Moon's avatar Hyundo Moon Committed by Gerrit Code Review
Browse files

Merge "Fix failing BluetoothPbapSimVcardManagerTest"

parents a8f8b39d 07d25029
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