[Settings] Rollback design for getSystemService(String)

Some of the design are intented for getSystemService(String).
Rollback those items.

Bug: 179640862
Test: local
Change-Id: I581070afb380a86c6352322f927c269b4527aee9
This commit is contained in:
Bonian Chen
2021-03-22 16:56:30 +08:00
parent 13fb77c652
commit 0fd51cc9ea

View File

@@ -94,7 +94,7 @@ public class EnabledNetworkModePreferenceControllerTest {
when(mContext.getSystemService(CarrierConfigManager.class)).thenReturn( when(mContext.getSystemService(CarrierConfigManager.class)).thenReturn(
mCarrierConfigManager); mCarrierConfigManager);
when(mContext.getSystemService(TelephonyManager.class)).thenReturn(mTelephonyManager); when(mContext.getSystemService(Context.TELEPHONY_SERVICE)).thenReturn(mTelephonyManager);
when(mContext.getSystemService(TelephonyManager.class)).thenReturn(mTelephonyManager); when(mContext.getSystemService(TelephonyManager.class)).thenReturn(mTelephonyManager);
doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID);
doReturn(mInvalidTelephonyManager).when(mTelephonyManager).createForSubscriptionId( doReturn(mInvalidTelephonyManager).when(mTelephonyManager).createForSubscriptionId(