Home
last modified time | relevance | path

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

123

/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()
109 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in isDialogNeeded_enableNonDefaultSimInMultiSimMode_returnTrue()
131 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in onPreferenceChange_singleSim_On_shouldEnableData()
142 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in onPreferenceChange_multiSim_On_shouldEnableData()
152 mController.init(mFragmentManager, SUB_ID); in isChecked_returnUserDataEnabled()
161 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in updateState_opportunistic_disabled()
[all …]
DApnPreferenceControllerTest.java51 private static final int SUB_ID = 2; field in ApnPreferenceControllerTest
73 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
80 mController.init(SUB_ID); in setUp()
91 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_apnSettingsNotSupported_returnUnavailable()
101 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_apnSettingsSupportedWithCDMA_returnAvailable()
111 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_apnSettingsSupportedWithGsm_returnAvailable()
119 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(null); in getAvailabilityStatus_carrierConfigNull_returnUnavailable()
131 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_hideCarrierNetworkSettings_returnUnavailable()
145 assertThat(intent.getIntExtra(ApnSettings.SUB_ID, 0)).isEqualTo(SUB_ID); in handPreferenceTreeClick_fireIntent()
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).isActiveSubscriptionId(SUB_ID); in displayPreference_subscriptionEnabled_categoryIsVisible()
79 doReturn(false).when(mSubscriptionManager).isActiveSubscriptionId(SUB_ID); in displayPreference_subscriptionDisabled_categoryIsNotVisible()
86 doReturn(true).when(mSubscriptionManager).isActiveSubscriptionId(SUB_ID); in onSubscriptionsChanged_subscriptionBecomesDisabled_categoryIsNotVisible()
88 doReturn(false).when(mSubscriptionManager).isActiveSubscriptionId(SUB_ID); in onSubscriptionsChanged_subscriptionBecomesDisabled_categoryIsNotVisible()
95 doReturn(false).when(mSubscriptionManager).isActiveSubscriptionId(SUB_ID); in onSubscriptionsChanged_subscriptionBecomesEnabled_categoryIsVisible()
97 doReturn(true).when(mSubscriptionManager).isActiveSubscriptionId(SUB_ID); in onSubscriptionsChanged_subscriptionBecomesEnabled_categoryIsVisible()
DEnabledNetworkModePreferenceControllerTest.java60 private static final int SUB_ID = 2; field in EnabledNetworkModePreferenceControllerTest
88 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
94 doReturn(mPersistableBundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in setUp()
100 mController.init(mLifecycle, SUB_ID); in setUp()
146 mController.init(mLifecycle, SUB_ID); in init_initShow4GForLTE()
157 mController.init(mLifecycle, SUB_ID); in init_initDisplay5gList_returnTrue()
174 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, in updateState_updateByNetworkMode() local
187 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, in updateState_updateByNetworkMode_useDefaultValue() local
395 doReturn(true).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateSuccess()
402 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, 0)).isEqualTo( in onPreferenceChange_updateSuccess() local
[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()
DPreferredNetworkModePreferenceControllerTest.java51 private static final int SUB_ID = 2; field in PreferredNetworkModePreferenceControllerTest
75 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
80 doReturn(mPersistableBundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in setUp()
86 mController.init(SUB_ID); in setUp()
130 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, in updateState_updateByNetworkMode() local
143 doReturn(true).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateSuccess()
150 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, 0)).isEqualTo( in onPreferenceChange_updateSuccess() local
156 doReturn(false).when(mTelephonyManager).setPreferredNetworkType(SUB_ID, in onPreferenceChange_updateFail()
163 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, 0)).isNotEqualTo( in onPreferenceChange_updateFail() local
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.java45 private static final int SUB_ID = 2; field in VideoCallingPreferenceControllerTest
69 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
74 doReturn(mCarrierConfig).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in setUp()
78 mController.init(SUB_ID); in setUp()
90 assertThat(mController.isVideoCallEnabled(SUB_ID, mImsManager)).isTrue(); in isVideoCallEnabled_allFlagsOn_returnTrue()
97 assertThat(mController.isVideoCallEnabled(SUB_ID, mImsManager)).isFalse(); in isVideoCallEnabled_disabledByPlatform_returnFalse()
106 assertThat(mController.isVideoCallEnabled(SUB_ID, mImsManager)).isFalse(); in isVideoCallEnabled_dataDisabled_returnFalse()
124 doReturn(TelephonyManager.CALL_STATE_IDLE).when(mTelephonyManager).getCallState(SUB_ID); in updateState_4gLteOnWithoutCall_checked()
DCarrierPreferenceControllerTest.java55 private static final int SUB_ID = 2; field in CarrierPreferenceControllerTest
78 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
85 mController.init(SUB_ID); in setUp()
95 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_cdmaWithFlagOff_returnUnavailable()
105 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_cdmaWithFlagOnreturnAvailable()
115 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in getAvailabilityStatus_gsmWithFlagOnreturnAvailable()
126 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in handlePreferenceClick_activityFound_openCarrierSettingActivity()
146 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in handlePreferenceClick_activityNotFound_DoNothing()
160 doReturn(bundle).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in handlePreferenceClick_activityNotConfigured_DoNothing()
DWifiCallingPreferenceControllerTest.java55 private static final int SUB_ID = 2; field in WifiCallingPreferenceControllerTest
79 mQueryImsState = new MockWifiCallingQueryImsState(mContext, SUB_ID); in setUp()
91 mController.init(SUB_ID); in setUp()
96 when(mController.getTelephonyManager(mContext, SUB_ID)).thenReturn(mTelephonyManager); in setUp()
99 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(mCarrierConfig); in setUp()
142 mController.init(SUB_ID); in updateState_wfcNonRoamingByConfig()
189 SubscriptionManager.INVALID_SUBSCRIPTION_ID)).isEqualTo(SUB_ID); in displayPreference_available_setsSubscriptionIdOnIntent()
DMobileDataSliceTest.java60 private static final int SUB_ID = 2; field in MobileDataSliceTest
79 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
81 doReturn(SUB_ID).when(mSubscriptionInfo).getSubscriptionId(); in setUp()
112 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in handleUriChange_turnedOn_updatesMobileData()
124 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in handleUriChange_turnedOff_updatesMobileData()
136 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in handleUriChange_turnedOff_airplaneModeOn_mobileDataDoesNotUpdate()
192 doReturn(mSubscriptionInfo).when(mSubscriptionManager).getActiveSubscriptionInfo(SUB_ID); in airplaneModeEnabled_slicePrimaryActionIsEmpty()
DNrDisabledInDsdsFooterPreferenceControllerTest.java41 private static final int SUB_ID = 111; field in NrDisabledInDsdsFooterPreferenceControllerTest
72 mController.init(SUB_ID); in isAvailable_dataOnAndDsdsAnd5GSupported_Available()
82 mController.init(SUB_ID); in isAvailable_5gNotSupported_notAvailable()
92 mController.init(SUB_ID); in isAvailable_mobileDataOff_notAvailable()
102 mController.init(SUB_ID); in isAvailable_singleSimMode_notAvailable()
DDataServiceSetupPreferenceControllerTest.java53 private static final int SUB_ID = 2; field in DataServiceSetupPreferenceControllerTest
75 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
83 doReturn(mCarrierConfig).when(mCarrierConfigManager).getConfigForSubId(SUB_ID); in setUp()
87 mController.init(SUB_ID); in setUp()
109 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()
/packages/modules/IPsec/tests/iketests/src/java/android/net/eap/
DEapSessionConfigTest.java47 private static final int SUB_ID = 1; field in EapSessionConfigTest
57 .setEapSimConfig(SUB_ID, APPTYPE_USIM) in testBuildEapSim()
65 assertEquals(SUB_ID, eapSimConfig.subId); in testBuildEapSim()
72 .setEapAkaConfig(SUB_ID, APPTYPE_USIM) in testBuildEapAka()
79 assertEquals(SUB_ID, eapAkaConfig.subId); in testBuildEapAka()
88 SUB_ID, APPTYPE_USIM, NETWORK_NAME, ALLOW_MISMATCHED_NETWORK_NAMES) in testBuildEapAkaPrime()
95 assertEquals(SUB_ID, eapAkaPrimeConfig.subId); in testBuildEapAkaPrime()
/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.java48 private static final int SUB_ID = 2; field in OpenNetworkSelectPagePreferenceControllerTest
76 when(mTelephonyManager.createForSubscriptionId(SUB_ID)).thenReturn(mTelephonyManager); in setUp()
80 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(mCarrierConfig); in setUp()
82 when(mSubscriptionInfo.getSubscriptionId()).thenReturn(SUB_ID); in setUp()
95 mController.init(SUB_ID); in setUp()
/packages/apps/Settings/tests/robotests/src/com/android/settings/network/telephony/cdma/
DCdmaSystemSelectPreferenceControllerTest.java48 private static final int SUB_ID = 2; field in CdmaSystemSelectPreferenceControllerTest
73 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
80 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(mCarrierConfig); in setUp()
85 mController.init(mPreferenceManager, SUB_ID); in setUp()
122 Settings.Global.PREFERRED_NETWORK_MODE + SUB_ID, in updateState_LteGSMWcdma_disabled() local
DCdmaSubscriptionPreferenceControllerTest.java47 private static final int SUB_ID = 2; field in CdmaSubscriptionPreferenceControllerTest
72 doReturn(mTelephonyManager).when(mTelephonyManager).createForSubscriptionId(SUB_ID); in setUp()
78 when(mCarrierConfigManager.getConfigForSubId(SUB_ID)).thenReturn(mCarrierConfig); in setUp()
82 mController.init(mPreferenceManager, SUB_ID); in setUp()
/packages/modules/IPsec/tests/iketests/src/java/com/android/internal/net/eap/statemachine/
DEapAkaPrimeTest.java39 protected static final int SUB_ID = 1; field in EapAkaPrimeTest
44 SUB_ID, APPTYPE_USIM, PEER_NETWORK_NAME, ALLOW_MISMATCHED_NETWORK_NAMES);
69 .createForSubscriptionId(SUB_ID); in setUp()
79 verify(mockTelephonyManagerFromContext).createForSubscriptionId(SUB_ID); in setUp()

123