Home
last modified time | relevance | path

Searched refs:SUB_ID (Results 1 – 25 of 47) sorted by relevance

12

/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/network/
DMobileNetworkUpdateManagerTest.java49 private static final int SUB_ID = 1; field in MobileNetworkUpdateManagerTest
69 setupMobileNetworkUpdateManager(SUB_ID); in onStart_receiverRegistered()
88 setupMobileNetworkUpdateManager(SUB_ID); in onStop_receiverUnregistered()
109 setupMobileNetworkUpdateManager(SUB_ID); in onStart_subscriptionListenerRegistered()
118 setupMobileNetworkUpdateManager(SUB_ID); in onStop_subscriptionListenerUnregistered()
129 setupMobileNetworkUpdateManager(SUB_ID); in onMobileNetworkUpdated_withInitialSubId_pickSubId()
131 createSubscriptionInfo(SUB_ID + 1), createSubscriptionInfo(SUB_ID + 2)); in onMobileNetworkUpdated_withInitialSubId_pickSubId()
134 verify(mMobileNetworkUpdateListener).onMobileNetworkUpdated(SUB_ID); in onMobileNetworkUpdated_withInitialSubId_pickSubId()
141 createSubscriptionInfo(SUB_ID + 1), createSubscriptionInfo(SUB_ID + 2)); in onMobileNetworkUpdated_withoutInitialSubId_pickDefaultSubId()
144 verify(mMobileNetworkUpdateListener).onMobileNetworkUpdated(SUB_ID + 1); in onMobileNetworkUpdated_withoutInitialSubId_pickDefaultSubId()
DMobileDataTogglePreferenceControllerTest.java61 private static final int SUB_ID = 1; field in MobileDataTogglePreferenceControllerTest
79 getShadowTelephonyManager().setTelephonyManagerForSubscriptionId(SUB_ID, mTelephonyManager); in setUp()
80 mController.setSubId(SUB_ID); in setUp()
109 Settings.Global.getUriFor(Settings.Global.MOBILE_DATA + SUB_ID))).isNotEmpty(); in onStart_multiSim_registersObserver()
125 createSubscriptionInfo(SUB_ID, /* isOpportunistic= */ true)); in refreshUi_isOpportunistic_isDisabled()
134 createSubscriptionInfo(SUB_ID, /* isOpportunistic= */ false)); in refreshUi_isNotOpportunistic_isEnabled()
211 ShadowSubscriptionManager.setDefaultDataSubscriptionId(SUB_ID); in handlePreferenceChanged_setTrue_isMultiSim_noOtherSimActive_enablesData()
212 getShadowSubscriptionManager().setCurrentActiveSubscriptionId(SUB_ID); in handlePreferenceChanged_setTrue_isMultiSim_noOtherSimActive_enablesData()
223 ShadowSubscriptionManager.setDefaultDataSubscriptionId(SUB_ID); in handlePreferenceChanged_setTrue_isMultiSim_noOtherSimActive_setsChecked()
224 getShadowSubscriptionManager().setCurrentActiveSubscriptionId(SUB_ID); in handlePreferenceChanged_setTrue_isMultiSim_noOtherSimActive_setsChecked()
[all …]
DMobileNetworkFragmentTest.java45 private static final int SUB_ID = 1; field in MobileNetworkFragmentTest
64 setUpFragmentWithSubId(SUB_ID, TEST_NAME); in onMobileNetworkUpdated_startWithArgument_updateTitle()
66 Collections.singletonList(createSubscriptionInfo(SUB_ID, TEST_NAME))); in onMobileNetworkUpdated_startWithArgument_updateTitle()
68 createSubscriptionInfo(SUB_ID + 1, TEST_NAME + "_1"), in onMobileNetworkUpdated_startWithArgument_updateTitle()
69 createSubscriptionInfo(SUB_ID + 2, TEST_NAME + "_2")); in onMobileNetworkUpdated_startWithArgument_updateTitle()
81 Collections.singletonList(createSubscriptionInfo(SUB_ID, TEST_NAME))); in onMobileNetworkUpdated_noArgumentProvided_updateTitle()
83 createSubscriptionInfo(SUB_ID + 1, TEST_NAME + "_1"), in onMobileNetworkUpdated_noArgumentProvided_updateTitle()
84 createSubscriptionInfo(SUB_ID + 2, TEST_NAME + "_2")); in onMobileNetworkUpdated_noArgumentProvided_updateTitle()
DRoamingPreferenceControllerTest.java62 private static final int SUB_ID = 1; field in RoamingPreferenceControllerTest
79 getShadowTelephonyManager().setTelephonyManagerForSubscriptionId(SUB_ID, mTelephonyManager); in setUp()
80 mController.setSubId(SUB_ID); in setUp()
105 Settings.Global.getUriFor(Settings.Global.DATA_ROAMING + SUB_ID))).isNotEmpty(); in onStart_registerObserver_additionalSubId()
170 getShadowCarrierConfigManager().setConfigForSubId(SUB_ID, bundle); in callChangeListener_toggleTrue_needsDialog_showDialog()
184 getShadowCarrierConfigManager().setConfigForSubId(SUB_ID, bundle); in confirmDialog_turnOnRoaming()
209 getShadowCarrierConfigManager().setConfigForSubId(SUB_ID, bundle); in callChangeListener_toggleTrue_doesntNeedDialog_turnOnRoaming()
/packages/apps/Settings/tests/robotests/src/com/android/settings/network/telephony/
DMobileDataPreferenceControllerTest.java51 private static final int SUB_ID = 2; field in MobileDataPreferenceControllerTest
78 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
85 ShadowSubscriptionManager.setDefaultDataSubscriptionId(SUB_ID); in setUp()
86 mController.init(mFragmentManager, SUB_ID); in setUp()
100 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in isDialogNeeded_disableSingleSim_returnFalse()
110 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in isDialogNeeded_enableNonDefaultSimInMultiSimMode_returnTrue()
132 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in onPreferenceChange_singleSim_On_shouldEnableData()
144 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in onPreferenceChange_multiSim_On_shouldEnableData()
155 mController.init(mFragmentManager, SUB_ID); in isChecked_returnUserDataEnabled()
164 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in updateState_opportunistic_disabled()
[all …]
DEnabledNetworkModePreferenceControllerTest.java50 private static final int SUB_ID = 2; field in EnabledNetworkModePreferenceControllerTest
72 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
77 doReturn(mPersistableBundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in setUp()
83 mController.init(SUB_ID); in setUp()
109 mController.init(SUB_ID); in init_initShow4GForLTE()
117 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, in updateState_updateByNetworkMode() local
130 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, in updateState_updateByNetworkMode_useDefaultValue() local
141 doReturn(true).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateSuccess()
148 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, 0)).isEqualTo( in onPreferenceChange_updateSuccess() local
154 doReturn(false).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateFail()
[all …]
DMmsMessagePreferenceControllerTest.java48 private static final int SUB_ID = 2; field in MmsMessagePreferenceControllerTest
67 when(mTelephonyManager.createForSubscriptionId(SUB_ID)).thenReturn(mTelephonyManager); in setUp()
71 ShadowSubscriptionManager.setDefaultDataSubscriptionId(SUB_ID); in setUp()
72 mController.init(SUB_ID); in setUp()
87 assertThat(mController.getAvailabilityStatus(SUB_ID)).isEqualTo(CONDITIONALLY_UNAVAILABLE); in getAvailabilityStatus_mobileDataOn_returnUnavailable()
94 assertThat(mController.getAvailabilityStatus(SUB_ID)).isEqualTo(CONDITIONALLY_UNAVAILABLE); in getAvailabilityStatus_meteredOff_returnUnavailable()
99 mController.init(SUB_ID); in getAvailabilityStatus_mobileDataOffWithValidSubId_returnAvailable()
103 assertThat(mController.getAvailabilityStatus(SUB_ID)).isEqualTo(AVAILABLE); in getAvailabilityStatus_mobileDataOffWithValidSubId_returnAvailable()
118 verify(mSubscriptionManager).setAlwaysAllowMmsData(SUB_ID, true); in setChecked_setDataIntoSubscriptionManager()
121 verify(mSubscriptionManager).setAlwaysAllowMmsData(SUB_ID, false); in setChecked_setDataIntoSubscriptionManager()
DApnPreferenceControllerTest.java53 private static final int SUB_ID = 2; field in ApnPreferenceControllerTest
75 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
82 mController.init(SUB_ID); in setUp()
93 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_apnSettingsNotSupported_returnUnavailable()
103 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_apnSettingsSupportedWithCDMA_returnAvailable()
113 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_apnSettingsSupportedWithGsm_returnAvailable()
121 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(null); in getAvailabilityStatus_carrierConfigNull_returnUnavailable()
133 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_hideCarrierNetworkSettings_returnUnavailable()
147 assertThat(intent.getIntExtra(ApnSettings.SUB_ID, 0)).isEqualTo(SUB_ID); in handPreferenceTreeClick_fireIntent()
DPreferredNetworkModePreferenceControllerTest.java49 private static final int SUB_ID = 2; field in PreferredNetworkModePreferenceControllerTest
71 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
75 doReturn(mPersistableBundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in setUp()
81 mController.init(SUB_ID); in setUp()
105 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, in updateState_updateByNetworkMode() local
118 doReturn(true).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateSuccess()
125 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, 0)).isEqualTo( in onPreferenceChange_updateSuccess() local
131 doReturn(false).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateFail()
138 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, 0)).isNotEqualTo( in onPreferenceChange_updateFail() local
DDisabledSubscriptionControllerTest.java45 private static final int SUB_ID = 111; field in DisabledSubscriptionControllerTest
67 mController.init(mLifecycle, SUB_ID); in setUp()
72 doReturn(true).when(mSubscriptionManager).isActiveSubId(SUB_ID); in displayPreference_subscriptionEnabled_categoryIsVisible()
79 doReturn(false).when(mSubscriptionManager).isActiveSubId(SUB_ID); in displayPreference_subscriptionDisabled_categoryIsNotVisible()
86 doReturn(true).when(mSubscriptionManager).isActiveSubId(SUB_ID); in onSubscriptionsChanged_subscriptionBecomesDisabled_categoryIsNotVisible()
88 doReturn(false).when(mSubscriptionManager).isActiveSubId(SUB_ID); in onSubscriptionsChanged_subscriptionBecomesDisabled_categoryIsNotVisible()
95 doReturn(false).when(mSubscriptionManager).isActiveSubId(SUB_ID); in onSubscriptionsChanged_subscriptionBecomesEnabled_categoryIsVisible()
97 doReturn(true).when(mSubscriptionManager).isActiveSubId(SUB_ID); in onSubscriptionsChanged_subscriptionBecomesEnabled_categoryIsVisible()
DDeleteSimProfilePreferenceControllerTest.java55 private static final int SUB_ID = 1234; field in DeleteSimProfilePreferenceControllerTest
75 when(mSubscriptionInfo.getSubscriptionId()).thenReturn(SUB_ID); in setUp()
93 mController.init(SUB_ID, mFragment, REQUEST_CODE); in getAvailabilityStatus_noSubs_notAvailable()
100 mController.init(SUB_ID, mFragment, REQUEST_CODE); in getAvailabilityStatus_physicalSim_notAvailable()
107 mController.init(SUB_ID, mFragment, REQUEST_CODE); in getAvailabilityStatus_unknownSim_notAvailable()
113 mController.init(SUB_ID, mFragment, REQUEST_CODE); in getAvailabilityStatus_knownEsim_isAvailable()
119 mController.init(SUB_ID, mFragment, REQUEST_CODE); in onPreferenceClick_startsIntent()
129 SubscriptionManager.INVALID_SUBSCRIPTION_ID)).isEqualTo(SUB_ID); in onPreferenceClick_startsIntent()
DVideoCallingPreferenceControllerTest.java44 private static final int SUB_ID = 2; field in VideoCallingPreferenceControllerTest
66 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
71 doReturn(mCarrierConfig).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in setUp()
75 mController.init(SUB_ID); in setUp()
87 assertThat(mController.isVideoCallEnabled(SUB_ID, mImsManager)).isTrue(); in isVideoCallEnabled_allFlagsOn_returnTrue()
94 assertThat(mController.isVideoCallEnabled(SUB_ID, mImsManager)).isFalse(); in isVideoCallEnabled_disabledByPlatform_returnFalse()
103 assertThat(mController.isVideoCallEnabled(SUB_ID, mImsManager)).isFalse(); in isVideoCallEnabled_dataDisabled_returnFalse()
121 doReturn(TelephonyManager.CALL_STATE_IDLE).when(mTelephonyManager).getCallState(SUB_ID); in updateState_4gLteOnWithoutCall_checked()
DCarrierPreferenceControllerTest.java56 private static final int SUB_ID = 2; field in CarrierPreferenceControllerTest
79 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
86 mController.init(SUB_ID); in setUp()
96 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_cdmaWithFlagOff_returnUnavailable()
106 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_cdmaWithFlagOnreturnAvailable()
116 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_gsmWithFlagOnreturnAvailable()
127 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in handlePreferenceClick_activityFound_openCarrierSettingActivity()
147 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in handlePreferenceClick_activityNotFound_DoNothing()
161 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in handlePreferenceClick_activityNotConfigured_DoNothing()
DWifiCallingPreferenceControllerTest.java54 private static final int SUB_ID = 2; field in WifiCallingPreferenceControllerTest
78 when(mTelephonyManager.createForSubscriptionId(SUB_ID)).thenReturn(mTelephonyManager); in setUp()
83 mController.init(SUB_ID); in setUp()
88 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(mCarrierConfig); in setUp()
113 when(mTelephonyManager.getCallState(SUB_ID)).thenReturn( in updateState_notCallIdle_disable()
134 mController.init(SUB_ID); in updateState_wfcNonRoaming()
180 SubscriptionManager.INVALID_SUBSCRIPTION_ID)).isEqualTo(SUB_ID); in displayPreference_available_setsSubscriptionIdOnIntent()
DMobileDataSliceTest.java59 private static final int SUB_ID = 2; field in MobileDataSliceTest
78 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
80 doReturn(SUB_ID).when(mSubscriptionInfo).getSubscriptionId(); in setUp()
111 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in handleUriChange_turnedOn_updatesMobileData()
123 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in handleUriChange_turnedOff_updatesMobileData()
135 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in handleUriChange_turnedOff_airplaneModeOn_mobileDataDoesNotUpdate()
191 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in airplaneModeEnabled_slicePrimaryActionIsEmpty()
DDataServiceSetupPreferenceControllerTest.java55 private static final int SUB_ID = 2; field in DataServiceSetupPreferenceControllerTest
77 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
85 doReturn(mCarrierConfig).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in setUp()
89 mController.init(SUB_ID); in setUp()
111 mController.init(SUB_ID); in getAvailabilityStatus_missUrl_returnUnavailable()
DDisableSimFooterPreferenceControllerTest.java42 private static final int SUB_ID = 111; field in DisableSimFooterPreferenceControllerTest
54 when(mInfo.getSubscriptionId()).thenReturn(SUB_ID); in setUp()
67 mController.init(SUB_ID); in isAvailable_eSIM_notAvailable()
74 mController.init(SUB_ID); in isAvailable_pSIM_available()
DEnhanced4gLtePreferenceControllerTest.java47 private static final int SUB_ID = 2; field in Enhanced4gLtePreferenceControllerTest
73 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
78 doReturn(mCarrierConfig).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in setUp()
82 mController.init(SUB_ID); in setUp()
165 doReturn(TelephonyManager.CALL_STATE_IDLE).when(mTelephonyManager).getCallState(SUB_ID); in updateState_configEnabled_prefEnabled()
DDataUsagePreferenceControllerTest.java49 private static final int SUB_ID = 2; field in DataUsagePreferenceControllerTest
65 shadowTelephonyManager.setTelephonyManagerForSubscriptionId(SUB_ID, telephonyManager); in setUp()
73 mController.init(SUB_ID); in setUp()
100 assertThat(intent.getIntExtra(Settings.EXTRA_SUB_ID, 0)).isEqualTo(SUB_ID); in handlePreferenceTreeClick_needDialog_showDialog()
DRoamingPreferenceControllerTest.java50 private static final int SUB_ID = 2; field in RoamingPreferenceControllerTest
77 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
84 mController.init(mFragmentManager, SUB_ID); in setUp()
106 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in isDialogNeeded_roamingDisabledWithoutFlag_returnTrue()
/packages/apps/Settings/tests/robotests/src/com/android/settings/network/telephony/gsm/
DAutoSelectPreferenceControllerTest.java49 private static final int SUB_ID = 2; field in AutoSelectPreferenceControllerTest
75 when(mTelephonyManager.createForSubscriptionId(SUB_ID)).thenReturn(mTelephonyManager); in setUp()
80 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(mCarrierConfig); in setUp()
86 mController.init(SUB_ID); in setUp()
125 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(null); in init_carrierConfigNull_shouldNotCrash()
128 mController.init(SUB_ID); in init_carrierConfigNull_shouldNotCrash()
DOpenNetworkSelectPagePreferenceControllerTest.java46 private static final int SUB_ID = 2; field in OpenNetworkSelectPagePreferenceControllerTest
72 when(mTelephonyManager.createForSubscriptionId(SUB_ID)).thenReturn(mTelephonyManager); in setUp()
76 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(mCarrierConfig); in setUp()
81 mController.init(SUB_ID); in setUp()
/packages/apps/Settings/tests/robotests/src/com/android/settings/network/telephony/cdma/
DCdmaSystemSelectPreferenceControllerTest.java46 private static final int SUB_ID = 2; field in CdmaSystemSelectPreferenceControllerTest
71 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
78 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(mCarrierConfig); in setUp()
83 mController.init(mPreferenceManager, SUB_ID); in setUp()
120 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, in updateState_LteGSMWcdma_disabled() local
DCdmaSubscriptionPreferenceControllerTest.java49 private static final int SUB_ID = 2; field in CdmaSubscriptionPreferenceControllerTest
74 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
80 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(mCarrierConfig); in setUp()
84 mController.init(mPreferenceManager, SUB_ID); in setUp()
DCdmaListPreferenceTest.java39 private static final int SUB_ID = 2; field in CdmaListPreferenceTest
56 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
59 mPreference.setSubId(SUB_ID); in setUp()

12