/packages/apps/Settings/tests/robotests/src/com/android/settings/deviceinfo/ |
D | StorageDashboardFragmentTest.java | 60 private StorageDashboardFragment mFragment; field in StorageDashboardFragmentTest 65 mFragment = new StorageDashboardFragment(); in setUp() 70 assertThat(mFragment.getCategoryKey()).isEqualTo(CategoryKey.CATEGORY_STORAGE); in testCategory_isConnectedDevice() 77 mFragment.initializeOptionsMenu(activity); in test_initializeOptionsMenuInvalidatesExistingMenu() 90 mFragment.setCachedStorageValuesHelper(helper); in test_cacheProviderProvidesValuesIfBothCached() 91 mFragment.initializeCachedValues(); in test_cacheProviderProvidesValuesIfBothCached() 93 assertThat(mFragment.getPrivateStorageInfo()).isEqualTo(info); in test_cacheProviderProvidesValuesIfBothCached() 94 assertThat(mFragment.getAppsStorageResult()).isEqualTo(result); in test_cacheProviderProvidesValuesIfBothCached() 103 mFragment.setCachedStorageValuesHelper(helper); in test_cacheProviderDoesntProvideValuesIfAppsMissing() 104 mFragment.initializeCachedValues(); in test_cacheProviderDoesntProvideValuesIfAppsMissing() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/fuelgauge/ |
D | PowerUsageSummaryTest.java | 161 private TestFragment mFragment; field in PowerUsageSummaryTest 181 mFragment = spy(new TestFragment(mContext)); in setUp() 182 mFragment.initFeatureProvider(); in setUp() 185 doNothing().when(mFragment).restartBatteryStatsLoader(); in setUp() 186 doReturn(mock(LoaderManager.class)).when(mFragment).getLoaderManager(); in setUp() 188 when(mFragment.getActivity()).thenReturn(mSettingsActivity); in setUp() 211 mFragment.setBatteryLayoutPreference(mBatteryLayoutPref); in setUp() 221 mFragment.mStatsHelper = mBatteryHelper; in setUp() 223 mFragment.mScreenUsagePref = mScreenUsagePref; in setUp() 224 mFragment.mLastFullChargePref = mLastFullChargePref; in setUp() [all …]
|
D | AdvancedPowerUsageDetailTest.java | 140 private AdvancedPowerUsageDetail mFragment; field in AdvancedPowerUsageDetailTest 153 mFragment = spy(new AdvancedPowerUsageDetail()); in setUp() 154 doReturn(mContext).when(mFragment).getContext(); in setUp() 155 doReturn(mActivity).when(mFragment).getActivity(); in setUp() 156 doReturn(SUMMARY).when(mFragment).getString(anyInt()); in setUp() 158 doReturn(mBundle).when(mFragment).getArguments(); in setUp() 159 doReturn(mLoaderManager).when(mFragment).getLoaderManager(); in setUp() 193 mFragment.mHeaderPreference = mHeaderPreference; in setUp() 194 mFragment.mState = mState; in setUp() 195 mFragment.mBatteryUtils = new BatteryUtils(RuntimeEnvironment.application); in setUp() [all …]
|
D | PowerUsageAnomalyDetailsTest.java | 89 private PowerUsageAnomalyDetails mFragment; field in PowerUsageAnomalyDetailsTest 121 mFragment = spy(new PowerUsageAnomalyDetails()); in setUp() 122 mFragment.mAbnormalListGroup = mAbnormalListGroup; in setUp() 123 mFragment.mAnomalies = mAnomalyList; in setUp() 124 mFragment.mBatteryUtils = new BatteryUtils(mContext); in setUp() 125 mFragment.mPackageManager = mPackageManager; in setUp() 126 mFragment.mIconDrawableFactory = mIconDrawableFactory; in setUp() 127 doReturn(mPreferenceManager).when(mFragment).getPreferenceManager(); in setUp() 145 mFragment.refreshUi(); in testRefreshUi_displayCorrectTitleAndSummary() 160 doReturn(mDrawable1).when(mFragment).getBadgedIcon(eq(PACKAGE_NAME_1), anyInt()); in testRefreshUi_iconCorrect() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/bluetooth/ |
D | DeviceListPreferenceFragmentTest.java | 64 private TestFragment mFragment; field in DeviceListPreferenceFragmentTest 71 mFragment = spy(new TestFragment()); in setUp() 72 doReturn(mContext).when(mFragment).getContext(); in setUp() 73 doReturn(mResource).when(mFragment).getResources(); in setUp() 74 mFragment.mLocalAdapter = mLocalAdapter; in setUp() 81 doReturn(FOOTAGE_MAC_STRING).when(mFragment).getString( in setUpdateMyDevicePreference_setTitleCorrectly() 84 mFragment.updateFooterPreference(mMyDevicePreference); in setUpdateMyDevicePreference_setTitleCorrectly() 91 mFragment.enableScanning(); in testEnableDisableScanning_testStateAfterEanbleDisable() 93 assertThat(mFragment.mScanEnabled).isTrue(); in testEnableDisableScanning_testStateAfterEanbleDisable() 95 mFragment.disableScanning(); in testEnableDisableScanning_testStateAfterEanbleDisable() [all …]
|
D | BluetoothPairingDetailTest.java | 68 private BluetoothPairingDetail mFragment; field in BluetoothPairingDetailTest 78 mFragment = spy(new BluetoothPairingDetail()); in setUp() 79 doReturn(mContext).when(mFragment).getContext(); in setUp() 80 doReturn(mResource).when(mFragment).getResources(); in setUp() 85 mFragment.mLocalAdapter = mLocalAdapter; in setUp() 86 mFragment.mLocalManager = mLocalManager; in setUp() 87 mFragment.mDeviceListGroup = mPreferenceGroup; in setUp() 88 mFragment.mAlwaysDiscoverable = new AlwaysDiscoverable(mContext, mLocalAdapter); in setUp() 93 doReturn(mAvailableDevicesCategory).when(mFragment).findPreference( in testInitPreferencesFromPreferenceScreen_findPreferences() 95 doReturn(mFooterPreference).when(mFragment).findPreference( in testInitPreferencesFromPreferenceScreen_findPreferences() [all …]
|
D | BluetoothSettingsTest.java | 70 private BluetoothSettings mFragment; field in BluetoothSettingsTest 84 mFragment = spy(new BluetoothSettings()); in setUp() 86 doReturn(mContext).when(mFragment).getContext(); in setUp() 87 doReturn(mResource).when(mFragment).getResources(); in setUp() 88 doReturn(mActivity).when(mFragment).getActivity(); in setUp() 96 mFragment.setLocalBluetoothAdapter(mLocalAdapter); in setUp() 97 mFragment.mPairingPrefController = mPairingPreferenceController; in setUp() 103 mFragment.setTextSpan(str, "hello"); in setTextSpan_notSpannable_shouldNotCrash() 108 doReturn(FOOTAGE_MAC_STRING).when(mFragment).getString( in setUpdateMyDevicePreference_setTitleCorrectly() 111 mFragment.updateFooterPreference(mFooterPreference); in setUpdateMyDevicePreference_setTitleCorrectly() [all …]
|
D | DeviceProfilesSettingsTest.java | 73 DeviceProfilesSettings mFragment; field in DeviceProfilesSettingsTest 85 mFragment = new DeviceProfilesSettings(); in setUp() 86 mFragment.setArguments(new Bundle()); in setUp() 101 FragmentTestUtil.startFragment(mFragment); in deviceHasHighQualityAudio() 103 ViewGroup profilesGroup = mFragment.getDialog().findViewById(R.id.profiles_section); in deviceHasHighQualityAudio() 123 FragmentTestUtil.startFragment(mFragment); in busyDeviceDisablesControl() 127 ViewGroup profilesGroup = mFragment.getDialog().findViewById(R.id.profiles_section); in busyDeviceDisablesControl() 140 FragmentTestUtil.startFragment(mFragment); in mediaAudioGetsDisabledAndReEnabled() 142 ViewGroup profilesGroup = mFragment.getDialog().findViewById(R.id.profiles_section); in mediaAudioGetsDisabledAndReEnabled() 153 mFragment.onDeviceAttributesChanged(); in mediaAudioGetsDisabledAndReEnabled() [all …]
|
D | BluetoothDeviceDetailsFragmentTest.java | 58 private BluetoothDeviceDetailsFragment mFragment; field in BluetoothDeviceDetailsFragmentTest 74 mFragment = spy(BluetoothDeviceDetailsFragment.newInstance(deviceAddress)); in setUp() 75 doReturn(mLocalManager).when(mFragment).getLocalBluetoothManager(any()); in setUp() 76 doReturn(mCachedDevice).when(mFragment).getCachedDevice(any()); in setUp() 81 mFragment.setArguments(args); in setUp() 82 mFragment.onAttach(mContext); in setUp() 89 mFragment.onCreateOptionsMenu(menu, inflater); in renameControlGetsAdded() 99 mFragment.onCreateOptionsMenu(menu, inflater); in renameControlClicked() 105 when(mFragment.getFragmentManager()).thenReturn(fragmentManager); in renameControlClicked() 110 mFragment.onOptionsItemSelected(item); in renameControlClicked()
|
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/dialog/old/ |
D | BaseContentFragment.java | 83 private final LiteFragment mFragment; field in BaseContentFragment 94 mFragment = fragment; in BaseContentFragment() 98 Bundle state = (savedInstanceState != null) ? savedInstanceState : mFragment.getArguments(); in onCreate() 176 if (mFragment.getView() == null) return null; in getIcon() 177 return (ImageView) mFragment.getView().findViewById(R.id.icon); in getIcon() 181 if (mFragment.getView() == null) return null; in getTitle() 182 return (TextView) mFragment.getView().findViewById(R.id.title); in getTitle() 198 return (RelativeLayout) mFragment.getView(); in getRoot() 202 if (mFragment.getView() == null) return null; in getBreadCrumb() 203 return (TextView) mFragment.getView().findViewById(R.id.breadcrumb); in getBreadCrumb() [all …]
|
D | BaseActionFragment.java | 36 private final LiteFragment mFragment; field in BaseActionFragment 71 mFragment = fragment; in BaseActionFragment() 102 mAdapter = new ActionAdapter(mFragment.getActivity()); in onCreate() 117 int startIndex = mFragment.getArguments().getInt(EXTRA_INDEX, -1); in onCreate() 124 mName = mFragment.getArguments().getString(EXTRA_NAME); in onCreate() 172 } else if (mFragment.getActivity() instanceof ActionAdapter.Listener) { in onActionClicked() 173 ActionAdapter.Listener listener = (ActionAdapter.Listener) mFragment.getActivity(); in onActionClicked() 180 if (mFragment.getActivity() instanceof ActionAdapter.OnFocusListener) { in onActionFocused() 181 ActionAdapter.OnFocusListener listener = (ActionAdapter.OnFocusListener) mFragment in onActionFocused() 189 if (mFragment.getActivity() instanceof ActionAdapter.OnKeyListener) { in onActionSelect() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/datausage/ |
D | AppDataUsageTest.java | 72 private AppDataUsage mFragment; field in AppDataUsageTest 91 mFragment = spy(new AppDataUsage()); in bindAppHeader_allWorkApps_shouldNotShowAppInfoLink() 94 .when(mFragment) in bindAppHeader_allWorkApps_shouldNotShowAppInfoLink() 96 doReturn(mock(PreferenceScreen.class)).when(mFragment).getPreferenceScreen(); in bindAppHeader_allWorkApps_shouldNotShowAppInfoLink() 97 ReflectionHelpers.setField(mFragment, "mAppItem", mock(AppItem.class)); in bindAppHeader_allWorkApps_shouldNotShowAppInfoLink() 99 mFragment.onViewCreated(new View(RuntimeEnvironment.application), new Bundle()); in bindAppHeader_allWorkApps_shouldNotShowAppInfoLink() 109 mFragment = spy(new AppDataUsage()); in bindAppHeader_workApp_shouldSetWorkAppUid() 114 ReflectionHelpers.setField(mFragment, "mPackageManagerWrapper", mPackageManagerWrapper); in bindAppHeader_workApp_shouldSetWorkAppUid() 115 ReflectionHelpers.setField(mFragment, "mAppItem", appItem); in bindAppHeader_workApp_shouldSetWorkAppUid() 116 ReflectionHelpers.setField(mFragment, "mPackages", packages); in bindAppHeader_workApp_shouldSetWorkAppUid() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/widget/ |
D | EntityHeaderControllerTest.java | 69 private Fragment mFragment; field in EntityHeaderControllerTest 84 when(mFragment.getContext()).thenReturn(mShadowContext); in setUp() 92 mController = EntityHeaderController.newInstance(mActivity, mFragment, null); in testBuildView_constructedWithoutView_shouldCreateNewView() 100 mController = EntityHeaderController.newInstance(mActivity, mFragment, null); in testBuildView_withContext_shouldBuildPreference() 109 mController = EntityHeaderController.newInstance(mActivity, mFragment, inputView); in testBuildView_constructedWithView_shouldReturnSameView() 123 mController = EntityHeaderController.newInstance(mActivity, mFragment, header); in bindViews_shouldBindAllData() 145 mController = EntityHeaderController.newInstance(mActivity, mFragment, appLinks); in bindButton_hasAppPref_shouldShowButton() 164 verify(mFragment).startActivity(any(Intent.class)); in bindButton_hasAppPref_shouldShowButton() 174 mController = EntityHeaderController.newInstance(mActivity, mFragment, appLinks); in bindButton_noAppPref_shouldNotShowButton() 192 when(mFragment.getActivity()).thenReturn(activity); in bindButton_noAppInfo_shouldNotAttachClickListener() [all …]
|
D | RadioButtonPickerFragmentTest.java | 59 private TestFragment mFragment; field in RadioButtonPickerFragmentTest 65 mFragment = spy(new TestFragment()); in setUp() 68 doReturn(mActivity).when(mFragment).getContext(); in setUp() 69 doReturn(mScreen).when(mFragment).getPreferenceScreen(); in setUp() 74 mFragment.onAttach((Context) mActivity); in onAttach_userIsInitialized() 86 mFragment.mayCheckOnlyRadioButton(); in displaySingleOption_shouldSelectRadioButton() 97 mFragment.onRadioButtonClicked(pref); in clickPreference_shouldConfirm() 99 assertThat(mFragment.setDefaultKeyCalled).isTrue(); in clickPreference_shouldConfirm()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/search/ |
D | IntentSearchViewHolderTest.java | 72 private SearchFragment mFragment; field in IntentSearchViewHolderTest 92 when(mFragment.getActivity().getPackageManager()).thenReturn(mPackageManager); in setUp() 106 mHolder.onBind(mFragment, result); in testBindViewElements_allUpdated() 115 verify(mFragment).onSearchResultClicked(eq(mHolder), any(SearchResult.class)); in testBindViewElements_allUpdated() 121 mHolder.onBind(mFragment, result); in testBindViewIcon_nullIcon_imageDrawableIsNull() 136 mHolder.onBind(mFragment, result); in testBindViewElements_emptySummary_hideSummaryView() 155 mHolder.onBind(mFragment, result); in testBindViewElements_withBreadcrumb_shouldFormatBreadcrumb() 170 mHolder.onBind(mFragment, result); in testBindElements_placeholderSummary_visibilityIsGone() 185 mHolder.onBind(mFragment, result); in testBindElements_dynamicSummary_visibilityIsGone() 197 mHolder.onBind(mFragment, result); in testBindViewElements_appSearchResult() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/display/ |
D | ColorModePreferenceFragmentTest.java | 45 private ColorModePreferenceFragment mFragment; field in ColorModePreferenceFragmentTest 55 mFragment = spy(new ColorModePreferenceFragment()); in setup() 56 ReflectionHelpers.setField(mFragment, "mController", mController); in setup() 61 assertThat(mFragment.getMetricsCategory()) in verifyMetricsConstant() 67 when(mFragment.getContext()).thenReturn(RuntimeEnvironment.application); in getCandidates() 69 mFragment.getCandidates(); in getCandidates() 86 assertThat(mFragment.getDefaultKey()) in getKey_natural() 96 assertThat(mFragment.getDefaultKey()) in getKey_boosted() 106 assertThat(mFragment.getDefaultKey()) in getKey_saturated() 113 mFragment.setDefaultKey(ColorModePreferenceFragment.KEY_COLOR_MODE_NATURAL); in setKey_natural() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/survey/ |
D | SurveyMixinTest.java | 47 private InstrumentedPreferenceFragment mFragment; field in SurveyMixinTest 67 when(mFragment.getActivity()).thenReturn(temp); in onResume_triesRegisteringReceiverAndDownloadingWhenNoSurveyDetected() 68 SurveyMixin mixin = new SurveyMixin(mFragment, FAKE_KEY); in onResume_triesRegisteringReceiverAndDownloadingWhenNoSurveyDetected() 86 when(mFragment.getActivity()).thenReturn(temp); in onResume_triesShowingSurveyWhenOneIsPresent() 87 SurveyMixin mixin = new SurveyMixin(mFragment, FAKE_KEY); in onResume_triesShowingSurveyWhenOneIsPresent() 101 when(mFragment.getActivity()).thenReturn(null); in onResume_doesNothingWhenActivityIsNull() 102 SurveyMixin mixin = new SurveyMixin(mFragment, FAKE_KEY); in onResume_doesNothingWhenActivityIsNull() 117 when(mFragment.getActivity()).thenReturn(temp); in onPause_removesReceiverIfPreviouslySet() 120 SurveyMixin mixin = new SurveyMixin(mFragment, FAKE_KEY); in onPause_removesReceiverIfPreviouslySet() 138 when(mFragment.getActivity()).thenReturn(temp); in onPause_doesNothingWhenActivityOrReceiverNull() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/ |
D | SettingsPreferenceFragmentTest.java | 61 private TestFragment mFragment; field in SettingsPreferenceFragmentTest 68 mFragment = spy(new TestFragment()); in setUp() 69 doReturn(mActivity).when(mFragment).getActivity(); in setUp() 72 ReflectionHelpers.setField(mFragment, "mEmptyView", mEmptyView); in setUp() 91 assertThat(mFragment.removePreference(mScreen, key)).isTrue(); in removePreference_nested_shouldRemove() 106 assertThat(mFragment.removePreference(mScreen, key)).isTrue(); in removePreference_flat_shouldRemove() 121 assertThat(mFragment.removePreference(mScreen, "not" + key)).isFalse(); in removePreference_doNotExist_shouldNotRemove() 129 doReturn(mPreferenceScreen).when(mFragment).getPreferenceScreen(); in testUpdateEmptyView_containerInvisible_emptyViewVisible() 131 mFragment.updateEmptyView(); in testUpdateEmptyView_containerInvisible_emptyViewVisible() 138 doReturn(mPreferenceScreen).when(mFragment).getPreferenceScreen(); in testUpdateEmptyView_containerNull_emptyViewGone() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/applications/defaultapps/ |
D | DefaultAppPickerFragmentTest.java | 63 private TestFragment mFragment; field in DefaultAppPickerFragmentTest 69 mFragment = spy(new TestFragment()); in setUp() 72 doReturn(mActivity).when(mFragment).getContext(); in setUp() 73 doReturn(mScreen).when(mFragment).getPreferenceScreen(); in setUp() 78 mFragment.onAttach((Context) mActivity); in clickPreference_hasConfirmation_shouldShowConfirmation() 82 doReturn("confirmation_text").when(mFragment) in clickPreference_hasConfirmation_shouldShowConfirmation() 84 doReturn(mActivity).when(mFragment).getActivity(); in clickPreference_hasConfirmation_shouldShowConfirmation() 86 mFragment.onRadioButtonClicked(pref); in clickPreference_hasConfirmation_shouldShowConfirmation() 91 mFragment.onAttach((Context) mActivity); in onRadioButtonConfirmed_shouldLog() 92 mFragment.onRadioButtonConfirmed("test_pkg"); in onRadioButtonConfirmed_shouldLog()
|
/packages/apps/Contacts/src/com/android/contacts/activities/ |
D | ContactEditorActivity.java | 257 private ContactEditor mFragment; field in ContactEditorActivity 360 mFragment = new ContactEditorFragment(); in onCreate() 371 mFragment = (ContactEditorFragment) getFragmentManager() in onCreate() 379 mFragment.setListener(mFragmentListener); in onCreate() 383 mFragment.load(action, uri, getIntent().getExtras()); in onCreate() 404 if (mFragment == null) { in onNewIntent() 410 mFragment.setIntentExtras(intent.getExtras()); in onNewIntent() 412 mFragment.onSaveCompleted(true, in onNewIntent() 419 mFragment.onJoinCompleted(intent.getData()); in onNewIntent() 459 if (mFragment != null) { in onBackPressed() [all …]
|
/packages/apps/Settings/src/com/android/settings/accounts/ |
D | AccountTypePreferenceLoader.java | 61 private PreferenceFragment mFragment; field in AccountTypePreferenceLoader 65 mFragment = fragment; in AccountTypePreferenceLoader() 89 final Context targetCtx = mFragment.getActivity().createPackageContextAsUser( in addPreferencesForType() 91 final Theme baseTheme = mFragment.getResources().newTheme(); in addPreferencesForType() 96 prefs = mFragment.getPreferenceManager().inflateFromResource(themedCtx, in addPreferencesForType() 116 final PackageManager pm = mFragment.getActivity().getPackageManager(); in updatePreferenceIntents() 165 mFragment.getActivity().startActivityAsUser( in updatePreferenceIntents() 225 ((SettingsActivity) mFragment.getActivity()).startPreferencePanel(mFragment, in onPreferenceClick() 231 mFragment.getActivity().sendBroadcast( in onPreferenceClick()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/accounts/ |
D | RemoveAccountPreferenceControllerTest.java | 74 private PreferenceFragment mFragment; field in RemoveAccountPreferenceControllerTest 94 when(mFragment.getPreferenceScreen()).thenReturn(mScreen); in setUp() 95 when(mFragment.getPreferenceManager().getContext()).thenReturn(mContext); in setUp() 96 when(mFragment.getFragmentManager()).thenReturn(mFragmentManager); in setUp() 101 mController = new RemoveAccountPreferenceController(mContext, mFragment, in setUp() 118 when(mFragment.isAdded()).thenReturn(true); in onClick_shouldStartConfirmDialog() 128 when(mFragment.isAdded()).thenReturn(true); in onClick_shouldNotStartConfirmDialogWhenModifyAccountsIsDisallowed() 141 when(mFragment.isAdded()).thenReturn(true); in confirmRemove_shouldRemoveAccount() 144 when(mFragment.getActivity()).thenReturn(activity); in confirmRemove_shouldRemoveAccount() 150 mFragment, account, userHandle); in confirmRemove_shouldRemoveAccount()
|
D | AccountDetailDashboardFragmentTest.java | 75 private AccountDetailDashboardFragment mFragment; field in AccountDetailDashboardFragmentTest 85 mFragment = spy(new AccountDetailDashboardFragment()); in setUp() 88 mFragment.setArguments(args); in setUp() 89 mFragment.mAccountType = "com.abc"; in setUp() 90 mFragment.mAccount = new Account("name1@abc.com", "com.abc"); in setUp() 107 assertThat(mFragment.displayTile(tile)).isTrue(); in refreshDashboardTiles_HasAccountType_shouldDisplay() 117 assertThat(mFragment.displayTile(tile)).isFalse(); in refreshDashboardTiles_NoAccountType_shouldNotDisplay() 128 assertThat(mFragment.displayTile(tile)).isFalse(); in refreshDashboardTiles_OtherAccountType_shouldNotDisplay() 151 mFragment.displayTile(tile); in refreshDashboardTiles_HasAccountType_shouldAddAccountNameToIntent()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/fingerprint/ |
D | DeleteFingerprintDialogTest.java | 52 private DeleteFingerprintDialog mFragment; field in DeleteFingerprintDialogTest 58 mFragment = DeleteFingerprintDialog.newInstance(mFingerprint, mTarget); in setUp() 63 FragmentTestUtil.startFragment(mFragment); in launchDialog_clickPositive_shouldDeleteFingerprint() 65 mFragment.onClick(mFragment.getDialog(), Dialog.BUTTON_POSITIVE); in launchDialog_clickPositive_shouldDeleteFingerprint() 72 FragmentTestUtil.startFragment(mFragment); in launchDialog_clickNegative_shouldDoNothing() 74 mFragment.onClick(mFragment.getDialog(), Dialog.BUTTON_NEGATIVE); in launchDialog_clickNegative_shouldDoNothing()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/password/ |
D | ChooseLockTypeDialogFragmentTest.java | 60 private TestFragment mFragment; field in ChooseLockTypeDialogFragmentTest 65 mFragment = new TestFragment(); in setUp() 66 FragmentTestUtil.startFragment(mFragment); in setUp() 81 mFragment.mDelegate = mock(OnLockTypeSelectedListener.class); in testThat_OnClickListener_IsCalled() 85 verify(mFragment.mDelegate, times(1)).onLockTypeSelected(any(ScreenLockType.class)); in testThat_OnClickListener_IsCalled() 90 mFragment.mDelegate = mock(OnLockTypeSelectedListener.class); in testThat_OnClickListener_IsNotCalledWhenCancelled() 93 verify(mFragment.mDelegate, never()).onLockTypeSelected(any(ScreenLockType.class)); in testThat_OnClickListener_IsNotCalledWhenCancelled() 100 chooseLockTypeDialogFragment.show(mFragment.getChildFragmentManager(), null); in startLockFragment()
|