Loading src/com/android/settings/network/telephony/RenameMobileNetworkDialogFragment.java +2 −1 Original line number Diff line number Diff line Loading @@ -149,7 +149,8 @@ public class RenameMobileNetworkDialogFragment extends InstrumentedDialogFragmen } final TextView operatorName = view.findViewById(R.id.operator_name_value); final ServiceState serviceState = mTelephonyManager.getServiceStateForSubscriber(mSubId); mTelephonyManager = mTelephonyManager.createForSubscriptionId(mSubId); final ServiceState serviceState = mTelephonyManager.getServiceState(); operatorName.setText(serviceState.getOperatorAlphaLong()); final TextView phoneTitle = view.findViewById(R.id.number_label); Loading tests/robotests/src/com/android/settings/network/telephony/RenameMobileNetworkDialogFragmentTest.java +2 −1 Original line number Diff line number Diff line Loading @@ -86,7 +86,8 @@ public class RenameMobileNetworkDialogFragmentTest { final ServiceState serviceState = mock(ServiceState.class); when(serviceState.getOperatorAlphaLong()).thenReturn("fake carrier name"); when(mTelephonyMgr.getServiceStateForSubscriber(mSubscriptionId)).thenReturn(serviceState); when(mTelephonyMgr.createForSubscriptionId(anyInt())).thenReturn(mTelephonyMgr); when(mTelephonyMgr.getServiceState()).thenReturn(serviceState); } @Test Loading Loading
src/com/android/settings/network/telephony/RenameMobileNetworkDialogFragment.java +2 −1 Original line number Diff line number Diff line Loading @@ -149,7 +149,8 @@ public class RenameMobileNetworkDialogFragment extends InstrumentedDialogFragmen } final TextView operatorName = view.findViewById(R.id.operator_name_value); final ServiceState serviceState = mTelephonyManager.getServiceStateForSubscriber(mSubId); mTelephonyManager = mTelephonyManager.createForSubscriptionId(mSubId); final ServiceState serviceState = mTelephonyManager.getServiceState(); operatorName.setText(serviceState.getOperatorAlphaLong()); final TextView phoneTitle = view.findViewById(R.id.number_label); Loading
tests/robotests/src/com/android/settings/network/telephony/RenameMobileNetworkDialogFragmentTest.java +2 −1 Original line number Diff line number Diff line Loading @@ -86,7 +86,8 @@ public class RenameMobileNetworkDialogFragmentTest { final ServiceState serviceState = mock(ServiceState.class); when(serviceState.getOperatorAlphaLong()).thenReturn("fake carrier name"); when(mTelephonyMgr.getServiceStateForSubscriber(mSubscriptionId)).thenReturn(serviceState); when(mTelephonyMgr.createForSubscriptionId(anyInt())).thenReturn(mTelephonyMgr); when(mTelephonyMgr.getServiceState()).thenReturn(serviceState); } @Test Loading