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

Commit 8a99ec27 authored by Xiangyu/Malcolm Chen's avatar Xiangyu/Malcolm Chen Committed by Android (Google) Code Review
Browse files

Merge "Clean up SubMgr#getOpportunisticSubscriptions."

parents db3fe553 f3ec3e90
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2322,7 +2322,7 @@ public class SubscriptionController extends ISub.Stub {
    }

    @Override
    public List<SubscriptionInfo> getOpportunisticSubscriptions(int slotId, String callingPackage) {
    public List<SubscriptionInfo> getOpportunisticSubscriptions(String callingPackage) {
        return getSubscriptionInfoListFromCacheHelper(
                callingPackage, mCacheOpportunisticSubInfoList);
    }
+2 −2
Original line number Diff line number Diff line
@@ -348,7 +348,7 @@ public class SubscriptionControllerTest extends TelephonyTest {
        // Neither sub1 or sub2 are opportunistic. So getOpportunisticSubscriptions
        // should return empty list and no callback triggered.
        List<SubscriptionInfo> opptSubList = mSubscriptionControllerUT
                .getOpportunisticSubscriptions(0, mCallingPackage);
                .getOpportunisticSubscriptions(mCallingPackage);

        assertTrue(opptSubList.isEmpty());
        verify(mTelephonyRegisteryMock, times(0))
@@ -360,7 +360,7 @@ public class SubscriptionControllerTest extends TelephonyTest {
        verify(mTelephonyRegisteryMock, times(1))
                .notifyOpportunisticSubscriptionInfoChanged();
        opptSubList = mSubscriptionControllerUT
                .getOpportunisticSubscriptions(0, mCallingPackage);
                .getOpportunisticSubscriptions(mCallingPackage);
        assertEquals(1, opptSubList.size());
        assertEquals("test2", opptSubList.get(0).getIccId());