Searched refs:mShadowContext (Results 1 – 6 of 6) sorted by relevance
59 private Context mShadowContext; field in ButtonActionDialogFragmentTest64 mShadowContext = RuntimeEnvironment.application; in setUp()67 doReturn(mShadowContext).when(mFragment).getContext(); in setUp()88 mShadowContext.getString(R.string.force_stop_dlg_text)); in testOnCreateDialog_forceStopDialog()90 mShadowContext.getString(R.string.force_stop_dlg_title)); in testOnCreateDialog_forceStopDialog()92 mShadowContext.getString(R.string.dlg_ok)); in testOnCreateDialog_forceStopDialog()94 mShadowContext.getString(R.string.dlg_cancel)); in testOnCreateDialog_forceStopDialog()107 mShadowContext.getString(R.string.app_disable_dlg_text)); in testOnCreateDialog_disableDialog()109 mShadowContext.getString(R.string.app_disable_dlg_positive)); in testOnCreateDialog_disableDialog()111 mShadowContext.getString(R.string.dlg_cancel)); in testOnCreateDialog_disableDialog()[all …]
99 private Context mShadowContext; field in PowerUsageAdvancedTest105 mShadowContext = spy(RuntimeEnvironment.application); in setUp()119 doReturn(mDischargingBatteryIntent).when(mShadowContext).registerReceiver(any(), any()); in setUp()124 when(mPowerUsageAdvanced.getContext()).thenReturn(mShadowContext); in setUp()127 doReturn(mShadowContext.getText(R.string.battery_used_for)).when( in setUp()132 mPowerUsageAdvanced.setBatteryUtils(BatteryUtils.getInstance(mShadowContext)); in setUp()133 when(mShadowContext.getSystemService(Context.CONNECTIVITY_SERVICE)).thenReturn( in setUp()144 PreferenceManager pm = new PreferenceManager(mShadowContext); in testPrefs_shouldNotBeSelectable()146 PreferenceGroup prefGroup = spy(new PreferenceCategory(mShadowContext)); in testPrefs_shouldNotBeSelectable()
76 private Context mShadowContext; field in BackgroundActivityPreferenceControllerTest82 mShadowContext = RuntimeEnvironment.application; in setUp()98 mPreference = new SwitchPreference(mShadowContext); in setUp()151 final CharSequence expectedSummary = mShadowContext.getText( in testUpdateSummary_modeError_showSummaryDisabled()163 final CharSequence expectedSummary = mShadowContext.getText( in testUpdateSummary_modeDefault_showSummaryOn()176 final CharSequence expectedSummary = mShadowContext.getText( in testUpdateSummary_modeIgnored_showSummaryOff()
71 private Context mShadowContext; field in EntityHeaderControllerTest81 mShadowContext = RuntimeEnvironment.application; in setUp()82 when(mActivity.getApplicationContext()).thenReturn(mShadowContext); in setUp()84 when(mFragment.getContext()).thenReturn(mShadowContext); in setUp()85 mLayoutInflater = LayoutInflater.from(mShadowContext); in setUp()101 Preference preference = mController.done(mActivity, mShadowContext); in testBuildView_withContext_shouldBuildPreference()126 mController.setIcon(mShadowContext.getDrawable(R.drawable.ic_add)); in bindViews_shouldBindAllData()241 mController.setIcon(mShadowContext.getDrawable(R.drawable.ic_add)); in iconContentDescription_shouldWorkWithSetIcon()
127 Context mShadowContext; field in AppInfoWithHeaderTest.TestFragment136 mShadowContext = ShadowApplication.getInstance().getApplicationContext(); in TestFragment()139 when(mManager.getContext()).thenReturn(mShadowContext); in TestFragment()169 return mShadowContext; in getContext()
127 private Context mShadowContext; field in InstalledAppDetailsTest135 mShadowContext = RuntimeEnvironment.application; in setUp()139 mBatteryPreference = new Preference(mShadowContext); in setUp()147 doReturn(mShadowContext).when(mAppDetail).getContext(); in setUp()444 doReturn(mShadowContext.getString(R.string.no_battery_summary)).when(mAppDetail).getString( in updateBattery_noBatteryStats_summaryNo()458 doReturn(mShadowContext.getString(R.string.battery_summary, BATTERY_LEVEL_STRING)).when( in updateBattery_hasBatteryStats_summaryPercent()