Loading flags/network.aconfig +0 −11 Original line number Original line Diff line number Diff line Loading @@ -37,17 +37,6 @@ flag { bug: "355062720" bug: "355062720" } } # OWNER=jackyu TARGET=25Q3 flag { name: "ignore_mcc_mnc_from_operator_for_locale" namespace: "telephony" description: "Ignoring mcc/mnc from RIL indication OPERATOR but only relying MCC/MNC from registered or nearby cells." bug:"374589521" metadata { purpose: PURPOSE_BUGFIX } } # OWNER=yomna TARGET=25Q4 # OWNER=yomna TARGET=25Q4 flag { flag { name: "vendor_specific_cellular_identifier_disclosure_indications" name: "vendor_specific_cellular_identifier_disclosure_indications" Loading src/java/com/android/internal/telephony/ServiceStateTracker.java +0 −20 Original line number Original line Diff line number Diff line Loading @@ -3888,26 +3888,6 @@ public class ServiceStateTracker extends Handler { tm.setNetworkOperatorNumericForPhone(mPhone.getPhoneId(), operatorNumeric); tm.setNetworkOperatorNumericForPhone(mPhone.getPhoneId(), operatorNumeric); String localeOperator = null; String localeOperator = null; if (!mFeatureFlags.ignoreMccMncFromOperatorForLocale()) { // If the OPERATOR command hasn't returned a valid operator or the device is on // IWLAN (because operatorNumeric would be SIM's mcc/mnc when device is on IWLAN), // but if the device has camped on a cell either to attempt registration or for // emergency services, then for purposes of setting the locale, we don't care if // registration fails or is incomplete. Additionally, if there is no cellular // service and ims is registered over the IWLAN, the locale will not be updated. // CellIdentity can return a null MCC and MNC in CDMA localeOperator = operatorNumeric; int dataNetworkType = mSS.getDataNetworkType(); if (dataNetworkType == TelephonyManager.NETWORK_TYPE_IWLAN || (dataNetworkType == TelephonyManager.NETWORK_TYPE_UNKNOWN && getImsRegistrationTech() == ImsRegistrationImplBase.REGISTRATION_TECH_IWLAN)) { // TODO(b/333346537#comment10): Complete solution would be ignore mcc/mnc // reported by the unsolicited indication OPERATOR from RIL, but only relies on // MCC/MNC from data registration or voice registration. localeOperator = null; } } if (isInvalidOperatorNumeric(localeOperator)) { if (isInvalidOperatorNumeric(localeOperator)) { for (CellIdentity cid : prioritizedCids) { for (CellIdentity cid : prioritizedCids) { if (!TextUtils.isEmpty(cid.getPlmn())) { if (!TextUtils.isEmpty(cid.getPlmn())) { Loading tests/telephonytests/src/com/android/internal/telephony/ServiceStateTrackerTest.java +11 −41 Original line number Original line Diff line number Diff line Loading @@ -129,7 +129,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { // Mocked classes // Mocked classes private ProxyController mProxyController; private ProxyController mProxyController; private Handler mTestHandler; private Handler mTestHandler; private NetworkService mIwlanNetworkService; private INetworkService.Stub mIwlanNetworkServiceStub; private INetworkService.Stub mIwlanNetworkServiceStub; private SubscriptionInfo mSubInfo; private SubscriptionInfo mSubInfo; Loading @@ -144,7 +143,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { private SignalStrengthController mSsc; private SignalStrengthController mSsc; private ServiceStateTracker sst; private ServiceStateTracker sst; private ServiceStateTrackerTestHandler mSSTTestHandler; private PersistableBundle mBundle; private PersistableBundle mBundle; private SatelliteController mSatelliteController; private SatelliteController mSatelliteController; private EmergencyStateTracker mEmergencyStateTracker; private EmergencyStateTracker mEmergencyStateTracker; Loading @@ -158,8 +156,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { private static final int EVENT_DATA_RAT_CHANGED = 7; private static final int EVENT_DATA_RAT_CHANGED = 7; private static final int EVENT_PS_RESTRICT_ENABLED = 8; private static final int EVENT_PS_RESTRICT_ENABLED = 8; private static final int EVENT_PS_RESTRICT_DISABLED = 9; private static final int EVENT_PS_RESTRICT_DISABLED = 9; private static final int EVENT_VOICE_ROAMING_ON = 10; private static final int EVENT_VOICE_ROAMING_OFF = 11; private static final int EVENT_VOICE_RAT_CHANGED = 12; private static final int EVENT_VOICE_RAT_CHANGED = 12; private static final int PHONE_ID = 0; private static final int PHONE_ID = 0; Loading @@ -177,6 +173,9 @@ public class ServiceStateTrackerTest extends TelephonyTest { WIFI_CALLING_FLIGHT_MODE_FORMAT }; WIFI_CALLING_FLIGHT_MODE_FORMAT }; private static final String HOME_PLMN = "310260"; private static final String HOME_PLMN = "310260"; private static final String HOME_MCC = "310"; private static final String HOME_MNC = "260"; private static final String PLMN1 = "480123"; private static final String PLMN1 = "480123"; private static final String PLMN2 = "586111"; private static final String PLMN2 = "586111"; private static final String HOME_PNN = "home pnn"; private static final String HOME_PNN = "home pnn"; Loading @@ -187,35 +186,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { }; }; private static final String SATELLITE_DISPLAY_NAME = "SatelliteTest"; private static final String SATELLITE_DISPLAY_NAME = "SatelliteTest"; private class ServiceStateTrackerTestHandler extends HandlerThread { private ServiceStateTrackerTestHandler(String name) { super(name); } @Override public void onLooperPrepared() { mSsc = new SignalStrengthController(mPhone); doReturn(mSsc).when(mPhone).getSignalStrengthController(); // Capture listener registered for ServiceStateTracker to emulate the carrier config // change notification used later. In this test, it's the third one. The first one // comes from RatRatcheter and the second one comes from SignalStrengthController. ArgumentCaptor<CarrierConfigManager.CarrierConfigChangeListener> listenerArgumentCaptor = ArgumentCaptor.forClass( CarrierConfigManager.CarrierConfigChangeListener.class); sst = new ServiceStateTracker(mPhone, mSimulatedCommands, mFeatureFlags); verify(mCarrierConfigManager, atLeast(3)).registerCarrierConfigChangeListener(any(), listenerArgumentCaptor.capture()); mCarrierConfigChangeListener = listenerArgumentCaptor.getAllValues().get(2); sst.setServiceStateStats(mServiceStateStats); doReturn(sst).when(mPhone).getServiceStateTracker(); setReady(true); } } private void addNetworkService() { private void addNetworkService() { mCellularNetworkService = new CellularNetworkService(); mCellularNetworkService = new CellularNetworkService(); ServiceInfo CellularServiceInfo = new ServiceInfo(); ServiceInfo CellularServiceInfo = new ServiceInfo(); Loading Loading @@ -253,7 +223,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { super.setUp(getClass().getSimpleName()); super.setUp(getClass().getSimpleName()); mProxyController = Mockito.mock(ProxyController.class); mProxyController = Mockito.mock(ProxyController.class); mTestHandler = Mockito.mock(Handler.class); mTestHandler = Mockito.mock(Handler.class); mIwlanNetworkService = Mockito.mock(NetworkService.class); mIwlanNetworkServiceStub = Mockito.mock(INetworkService.Stub.class); mIwlanNetworkServiceStub = Mockito.mock(INetworkService.Stub.class); mSubInfo = Mockito.mock(SubscriptionInfo.class); mSubInfo = Mockito.mock(SubscriptionInfo.class); mSubInfoInternal = new SubscriptionInfoInternal.Builder().setId(1).build(); mSubInfoInternal = new SubscriptionInfoInternal.Builder().setId(1).build(); Loading Loading @@ -2369,7 +2338,7 @@ public class ServiceStateTrackerTest extends TelephonyTest { new LteVopsSupportInfo(LteVopsSupportInfo.LTE_STATUS_NOT_AVAILABLE, new LteVopsSupportInfo(LteVopsSupportInfo.LTE_STATUS_NOT_AVAILABLE, LteVopsSupportInfo.LTE_STATUS_NOT_AVAILABLE); LteVopsSupportInfo.LTE_STATUS_NOT_AVAILABLE); CellIdentityLte cellIdentity = CellIdentityLte cellIdentity = new CellIdentityLte(1, 1, 5, 1, new int[] {1, 2}, 5000, "001", "01", "test", new CellIdentityLte(1, 1, 5, 1, new int[] {1, 2}, 5000, HOME_MCC, HOME_MNC, "test", "tst", Collections.emptyList(), null); "tst", Collections.emptyList(), null); if (!passCellId) { if (!passCellId) { cellIdentity = null; cellIdentity = null; Loading @@ -2380,7 +2349,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { new AsyncResult(sst.mPollingContext, opNamesResult, null))); new AsyncResult(sst.mPollingContext, opNamesResult, null))); processAllMessages(); processAllMessages(); // PS WWAN // PS WWAN NetworkRegistrationInfo dataResult = new NetworkRegistrationInfo( NetworkRegistrationInfo dataResult = new NetworkRegistrationInfo( NetworkRegistrationInfo.DOMAIN_PS, AccessNetworkConstants.TRANSPORT_TYPE_WWAN, NetworkRegistrationInfo.DOMAIN_PS, AccessNetworkConstants.TRANSPORT_TYPE_WWAN, Loading Loading @@ -2408,7 +2376,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { processAllMessages(); processAllMessages(); assertEquals(opNamesResult[0], sst.getServiceState().getOperatorAlpha()); assertEquals(opNamesResult[0], sst.getServiceState().getOperatorAlpha()); assertEquals(opNamesResult[2], sst.getServiceState().getOperatorNumeric()); assertEquals(opNamesResult[2], sst.getServiceState().getOperatorNumeric()); verify(mLocaleTracker).updateOperatorNumeric(eq(opNamesResult[2])); } } /** /** Loading @@ -2424,13 +2391,14 @@ public class ServiceStateTrackerTest extends TelephonyTest { changeRegStateWithIwlanOperatorNumeric(NetworkRegistrationInfo.REGISTRATION_STATE_HOME, changeRegStateWithIwlanOperatorNumeric(NetworkRegistrationInfo.REGISTRATION_STATE_HOME, TelephonyManager.NETWORK_TYPE_LTE, TelephonyManager.NETWORK_TYPE_LTE, NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); verify(mLocaleTracker).updateOperatorNumeric(eq(OpNamesResult[2])); verify(mLocaleTracker).updateOperatorNumeric(eq(HOME_MCC + HOME_MNC)); Mockito.clearInvocations(mLocaleTracker); changeRegStateWithIwlanOperatorNumeric( changeRegStateWithIwlanOperatorNumeric( NetworkRegistrationInfo.REGISTRATION_STATE_NOT_REGISTERED_OR_SEARCHING, NetworkRegistrationInfo.REGISTRATION_STATE_NOT_REGISTERED_OR_SEARCHING, TelephonyManager.NETWORK_TYPE_LTE, TelephonyManager.NETWORK_TYPE_LTE, NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); /* cellId based mccmnc */ /* cellId based mccmnc */ verify(mLocaleTracker).updateOperatorNumeric(eq("00101")); verify(mLocaleTracker).updateOperatorNumeric(eq(HOME_MCC + HOME_MNC)); changeRegStateWithIwlanOperatorNumeric( changeRegStateWithIwlanOperatorNumeric( NetworkRegistrationInfo.REGISTRATION_STATE_NOT_REGISTERED_OR_SEARCHING, NetworkRegistrationInfo.REGISTRATION_STATE_NOT_REGISTERED_OR_SEARCHING, TelephonyManager.NETWORK_TYPE_LTE, TelephonyManager.NETWORK_TYPE_LTE, Loading @@ -2455,7 +2423,9 @@ public class ServiceStateTrackerTest extends TelephonyTest { NetworkRegistrationInfo.REGISTRATION_STATE_HOME, NetworkRegistrationInfo.REGISTRATION_STATE_HOME, TelephonyManager.NETWORK_TYPE_LTE, TelephonyManager.NETWORK_TYPE_LTE, NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); verify(mLocaleTracker).updateOperatorNumeric(eq(OpNamesResult[2])); verify(mLocaleTracker).updateOperatorNumeric(eq(HOME_MCC + HOME_MNC)); clearInvocations(mLocaleTracker); // Test with Cellular as NOT_REG // Test with Cellular as NOT_REG changeRegStateWithIwlanOperatorNumeric( changeRegStateWithIwlanOperatorNumeric( Loading @@ -2463,7 +2433,7 @@ public class ServiceStateTrackerTest extends TelephonyTest { TelephonyManager.NETWORK_TYPE_UNKNOWN, TelephonyManager.NETWORK_TYPE_UNKNOWN, NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); /* cellId based mccmnc */ /* cellId based mccmnc */ verify(mLocaleTracker).updateOperatorNumeric(eq("00101")); verify(mLocaleTracker).updateOperatorNumeric(eq(HOME_MCC + HOME_MNC)); // IMS over Iwlan is registered. // IMS over Iwlan is registered. doReturn(mImsPhone) doReturn(mImsPhone) Loading Loading
flags/network.aconfig +0 −11 Original line number Original line Diff line number Diff line Loading @@ -37,17 +37,6 @@ flag { bug: "355062720" bug: "355062720" } } # OWNER=jackyu TARGET=25Q3 flag { name: "ignore_mcc_mnc_from_operator_for_locale" namespace: "telephony" description: "Ignoring mcc/mnc from RIL indication OPERATOR but only relying MCC/MNC from registered or nearby cells." bug:"374589521" metadata { purpose: PURPOSE_BUGFIX } } # OWNER=yomna TARGET=25Q4 # OWNER=yomna TARGET=25Q4 flag { flag { name: "vendor_specific_cellular_identifier_disclosure_indications" name: "vendor_specific_cellular_identifier_disclosure_indications" Loading
src/java/com/android/internal/telephony/ServiceStateTracker.java +0 −20 Original line number Original line Diff line number Diff line Loading @@ -3888,26 +3888,6 @@ public class ServiceStateTracker extends Handler { tm.setNetworkOperatorNumericForPhone(mPhone.getPhoneId(), operatorNumeric); tm.setNetworkOperatorNumericForPhone(mPhone.getPhoneId(), operatorNumeric); String localeOperator = null; String localeOperator = null; if (!mFeatureFlags.ignoreMccMncFromOperatorForLocale()) { // If the OPERATOR command hasn't returned a valid operator or the device is on // IWLAN (because operatorNumeric would be SIM's mcc/mnc when device is on IWLAN), // but if the device has camped on a cell either to attempt registration or for // emergency services, then for purposes of setting the locale, we don't care if // registration fails or is incomplete. Additionally, if there is no cellular // service and ims is registered over the IWLAN, the locale will not be updated. // CellIdentity can return a null MCC and MNC in CDMA localeOperator = operatorNumeric; int dataNetworkType = mSS.getDataNetworkType(); if (dataNetworkType == TelephonyManager.NETWORK_TYPE_IWLAN || (dataNetworkType == TelephonyManager.NETWORK_TYPE_UNKNOWN && getImsRegistrationTech() == ImsRegistrationImplBase.REGISTRATION_TECH_IWLAN)) { // TODO(b/333346537#comment10): Complete solution would be ignore mcc/mnc // reported by the unsolicited indication OPERATOR from RIL, but only relies on // MCC/MNC from data registration or voice registration. localeOperator = null; } } if (isInvalidOperatorNumeric(localeOperator)) { if (isInvalidOperatorNumeric(localeOperator)) { for (CellIdentity cid : prioritizedCids) { for (CellIdentity cid : prioritizedCids) { if (!TextUtils.isEmpty(cid.getPlmn())) { if (!TextUtils.isEmpty(cid.getPlmn())) { Loading
tests/telephonytests/src/com/android/internal/telephony/ServiceStateTrackerTest.java +11 −41 Original line number Original line Diff line number Diff line Loading @@ -129,7 +129,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { // Mocked classes // Mocked classes private ProxyController mProxyController; private ProxyController mProxyController; private Handler mTestHandler; private Handler mTestHandler; private NetworkService mIwlanNetworkService; private INetworkService.Stub mIwlanNetworkServiceStub; private INetworkService.Stub mIwlanNetworkServiceStub; private SubscriptionInfo mSubInfo; private SubscriptionInfo mSubInfo; Loading @@ -144,7 +143,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { private SignalStrengthController mSsc; private SignalStrengthController mSsc; private ServiceStateTracker sst; private ServiceStateTracker sst; private ServiceStateTrackerTestHandler mSSTTestHandler; private PersistableBundle mBundle; private PersistableBundle mBundle; private SatelliteController mSatelliteController; private SatelliteController mSatelliteController; private EmergencyStateTracker mEmergencyStateTracker; private EmergencyStateTracker mEmergencyStateTracker; Loading @@ -158,8 +156,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { private static final int EVENT_DATA_RAT_CHANGED = 7; private static final int EVENT_DATA_RAT_CHANGED = 7; private static final int EVENT_PS_RESTRICT_ENABLED = 8; private static final int EVENT_PS_RESTRICT_ENABLED = 8; private static final int EVENT_PS_RESTRICT_DISABLED = 9; private static final int EVENT_PS_RESTRICT_DISABLED = 9; private static final int EVENT_VOICE_ROAMING_ON = 10; private static final int EVENT_VOICE_ROAMING_OFF = 11; private static final int EVENT_VOICE_RAT_CHANGED = 12; private static final int EVENT_VOICE_RAT_CHANGED = 12; private static final int PHONE_ID = 0; private static final int PHONE_ID = 0; Loading @@ -177,6 +173,9 @@ public class ServiceStateTrackerTest extends TelephonyTest { WIFI_CALLING_FLIGHT_MODE_FORMAT }; WIFI_CALLING_FLIGHT_MODE_FORMAT }; private static final String HOME_PLMN = "310260"; private static final String HOME_PLMN = "310260"; private static final String HOME_MCC = "310"; private static final String HOME_MNC = "260"; private static final String PLMN1 = "480123"; private static final String PLMN1 = "480123"; private static final String PLMN2 = "586111"; private static final String PLMN2 = "586111"; private static final String HOME_PNN = "home pnn"; private static final String HOME_PNN = "home pnn"; Loading @@ -187,35 +186,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { }; }; private static final String SATELLITE_DISPLAY_NAME = "SatelliteTest"; private static final String SATELLITE_DISPLAY_NAME = "SatelliteTest"; private class ServiceStateTrackerTestHandler extends HandlerThread { private ServiceStateTrackerTestHandler(String name) { super(name); } @Override public void onLooperPrepared() { mSsc = new SignalStrengthController(mPhone); doReturn(mSsc).when(mPhone).getSignalStrengthController(); // Capture listener registered for ServiceStateTracker to emulate the carrier config // change notification used later. In this test, it's the third one. The first one // comes from RatRatcheter and the second one comes from SignalStrengthController. ArgumentCaptor<CarrierConfigManager.CarrierConfigChangeListener> listenerArgumentCaptor = ArgumentCaptor.forClass( CarrierConfigManager.CarrierConfigChangeListener.class); sst = new ServiceStateTracker(mPhone, mSimulatedCommands, mFeatureFlags); verify(mCarrierConfigManager, atLeast(3)).registerCarrierConfigChangeListener(any(), listenerArgumentCaptor.capture()); mCarrierConfigChangeListener = listenerArgumentCaptor.getAllValues().get(2); sst.setServiceStateStats(mServiceStateStats); doReturn(sst).when(mPhone).getServiceStateTracker(); setReady(true); } } private void addNetworkService() { private void addNetworkService() { mCellularNetworkService = new CellularNetworkService(); mCellularNetworkService = new CellularNetworkService(); ServiceInfo CellularServiceInfo = new ServiceInfo(); ServiceInfo CellularServiceInfo = new ServiceInfo(); Loading Loading @@ -253,7 +223,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { super.setUp(getClass().getSimpleName()); super.setUp(getClass().getSimpleName()); mProxyController = Mockito.mock(ProxyController.class); mProxyController = Mockito.mock(ProxyController.class); mTestHandler = Mockito.mock(Handler.class); mTestHandler = Mockito.mock(Handler.class); mIwlanNetworkService = Mockito.mock(NetworkService.class); mIwlanNetworkServiceStub = Mockito.mock(INetworkService.Stub.class); mIwlanNetworkServiceStub = Mockito.mock(INetworkService.Stub.class); mSubInfo = Mockito.mock(SubscriptionInfo.class); mSubInfo = Mockito.mock(SubscriptionInfo.class); mSubInfoInternal = new SubscriptionInfoInternal.Builder().setId(1).build(); mSubInfoInternal = new SubscriptionInfoInternal.Builder().setId(1).build(); Loading Loading @@ -2369,7 +2338,7 @@ public class ServiceStateTrackerTest extends TelephonyTest { new LteVopsSupportInfo(LteVopsSupportInfo.LTE_STATUS_NOT_AVAILABLE, new LteVopsSupportInfo(LteVopsSupportInfo.LTE_STATUS_NOT_AVAILABLE, LteVopsSupportInfo.LTE_STATUS_NOT_AVAILABLE); LteVopsSupportInfo.LTE_STATUS_NOT_AVAILABLE); CellIdentityLte cellIdentity = CellIdentityLte cellIdentity = new CellIdentityLte(1, 1, 5, 1, new int[] {1, 2}, 5000, "001", "01", "test", new CellIdentityLte(1, 1, 5, 1, new int[] {1, 2}, 5000, HOME_MCC, HOME_MNC, "test", "tst", Collections.emptyList(), null); "tst", Collections.emptyList(), null); if (!passCellId) { if (!passCellId) { cellIdentity = null; cellIdentity = null; Loading @@ -2380,7 +2349,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { new AsyncResult(sst.mPollingContext, opNamesResult, null))); new AsyncResult(sst.mPollingContext, opNamesResult, null))); processAllMessages(); processAllMessages(); // PS WWAN // PS WWAN NetworkRegistrationInfo dataResult = new NetworkRegistrationInfo( NetworkRegistrationInfo dataResult = new NetworkRegistrationInfo( NetworkRegistrationInfo.DOMAIN_PS, AccessNetworkConstants.TRANSPORT_TYPE_WWAN, NetworkRegistrationInfo.DOMAIN_PS, AccessNetworkConstants.TRANSPORT_TYPE_WWAN, Loading Loading @@ -2408,7 +2376,6 @@ public class ServiceStateTrackerTest extends TelephonyTest { processAllMessages(); processAllMessages(); assertEquals(opNamesResult[0], sst.getServiceState().getOperatorAlpha()); assertEquals(opNamesResult[0], sst.getServiceState().getOperatorAlpha()); assertEquals(opNamesResult[2], sst.getServiceState().getOperatorNumeric()); assertEquals(opNamesResult[2], sst.getServiceState().getOperatorNumeric()); verify(mLocaleTracker).updateOperatorNumeric(eq(opNamesResult[2])); } } /** /** Loading @@ -2424,13 +2391,14 @@ public class ServiceStateTrackerTest extends TelephonyTest { changeRegStateWithIwlanOperatorNumeric(NetworkRegistrationInfo.REGISTRATION_STATE_HOME, changeRegStateWithIwlanOperatorNumeric(NetworkRegistrationInfo.REGISTRATION_STATE_HOME, TelephonyManager.NETWORK_TYPE_LTE, TelephonyManager.NETWORK_TYPE_LTE, NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); verify(mLocaleTracker).updateOperatorNumeric(eq(OpNamesResult[2])); verify(mLocaleTracker).updateOperatorNumeric(eq(HOME_MCC + HOME_MNC)); Mockito.clearInvocations(mLocaleTracker); changeRegStateWithIwlanOperatorNumeric( changeRegStateWithIwlanOperatorNumeric( NetworkRegistrationInfo.REGISTRATION_STATE_NOT_REGISTERED_OR_SEARCHING, NetworkRegistrationInfo.REGISTRATION_STATE_NOT_REGISTERED_OR_SEARCHING, TelephonyManager.NETWORK_TYPE_LTE, TelephonyManager.NETWORK_TYPE_LTE, NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); /* cellId based mccmnc */ /* cellId based mccmnc */ verify(mLocaleTracker).updateOperatorNumeric(eq("00101")); verify(mLocaleTracker).updateOperatorNumeric(eq(HOME_MCC + HOME_MNC)); changeRegStateWithIwlanOperatorNumeric( changeRegStateWithIwlanOperatorNumeric( NetworkRegistrationInfo.REGISTRATION_STATE_NOT_REGISTERED_OR_SEARCHING, NetworkRegistrationInfo.REGISTRATION_STATE_NOT_REGISTERED_OR_SEARCHING, TelephonyManager.NETWORK_TYPE_LTE, TelephonyManager.NETWORK_TYPE_LTE, Loading @@ -2455,7 +2423,9 @@ public class ServiceStateTrackerTest extends TelephonyTest { NetworkRegistrationInfo.REGISTRATION_STATE_HOME, NetworkRegistrationInfo.REGISTRATION_STATE_HOME, TelephonyManager.NETWORK_TYPE_LTE, TelephonyManager.NETWORK_TYPE_LTE, NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); verify(mLocaleTracker).updateOperatorNumeric(eq(OpNamesResult[2])); verify(mLocaleTracker).updateOperatorNumeric(eq(HOME_MCC + HOME_MNC)); clearInvocations(mLocaleTracker); // Test with Cellular as NOT_REG // Test with Cellular as NOT_REG changeRegStateWithIwlanOperatorNumeric( changeRegStateWithIwlanOperatorNumeric( Loading @@ -2463,7 +2433,7 @@ public class ServiceStateTrackerTest extends TelephonyTest { TelephonyManager.NETWORK_TYPE_UNKNOWN, TelephonyManager.NETWORK_TYPE_UNKNOWN, NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); NetworkRegistrationInfo.REGISTRATION_STATE_HOME, OpNamesResult, true); /* cellId based mccmnc */ /* cellId based mccmnc */ verify(mLocaleTracker).updateOperatorNumeric(eq("00101")); verify(mLocaleTracker).updateOperatorNumeric(eq(HOME_MCC + HOME_MNC)); // IMS over Iwlan is registered. // IMS over Iwlan is registered. doReturn(mImsPhone) doReturn(mImsPhone) Loading