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

Commit cee0d31f authored by Grant Menke's avatar Grant Menke
Browse files

Use ID 12 for other user ID in CallsManagerTest.

The content URI of a different user was using  User ID 10 in BasicCallTests. This was causing some of the tests to fail on HSUM devices since on those devices there is an actual user with user ID 10. This CL uses user ID 12 instead to prevent confliction with the actual user 10 on HSUM devices.

Test: BasicCallTests
Bug: 383204897
Flag: TEST_ONLY
Change-Id: Ib0f0443a80b8680c9ad87d7195257c02732b1bcb
parent 2d78eb59
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -1282,7 +1282,7 @@ public class BasicCallTests extends TelecomSystemTest {
        // Stub intent for call2
        Intent callIntent2 = new Intent();
        Bundle callExtras1 = new Bundle();
        Icon icon = Icon.createWithContentUri("content://10@media/external/images/media/");
        Icon icon = Icon.createWithContentUri("content://12@media/external/images/media/");
        // Load StatusHints extra into TelecomManager.EXTRA_OUTGOING_CALL_EXTRAS to be processed
        // as the call extras. This will be leveraged in ConnectionServiceFixture to set the
        // StatusHints for the given connection.
@@ -1315,7 +1315,7 @@ public class BasicCallTests extends TelecomSystemTest {
    @Test
    public void testValidateStatusHintsImage_handleCreateConnectionComplete() throws Exception {
        Bundle extras = new Bundle();
        Icon icon = Icon.createWithContentUri("content://10@media/external/images/media/");
        Icon icon = Icon.createWithContentUri("content://12@media/external/images/media/");
        // Load the bundle with the test extra in order to simulate an app directly invoking the
        // binder on ConnectionServiceWrapper#handleCreateConnectionComplete.
        StatusHints statusHints = new StatusHints(icon);
@@ -1349,7 +1349,7 @@ public class BasicCallTests extends TelecomSystemTest {
                mPhoneAccountA0.getAccountHandle(), mConnectionServiceFixtureA);

        // Modify existing connection with StatusHints image exploit
        Icon icon = Icon.createWithContentUri("content://10@media/external/images/media/");
        Icon icon = Icon.createWithContentUri("content://12@media/external/images/media/");
        StatusHints statusHints = new StatusHints(icon);
        assertNotNull(statusHints.getIcon());
        ConnectionServiceFixture.ConnectionInfo connectionInfo = mConnectionServiceFixtureA
@@ -1384,7 +1384,7 @@ public class BasicCallTests extends TelecomSystemTest {
                mPhoneAccountA0.getAccountHandle(), mConnectionServiceFixtureA);

        // Modify existing connection with StatusHints image exploit
        Icon icon = Icon.createWithContentUri("content://10@media/external/images/media/");
        Icon icon = Icon.createWithContentUri("content://12@media/external/images/media/");
        StatusHints modifiedStatusHints = new StatusHints(icon);
        assertNotNull(modifiedStatusHints.getIcon());
        ConnectionServiceFixture.ConnectionInfo connectionInfo = mConnectionServiceFixtureA