/cts/tests/tests/permission/src/android/permission/cts/ |
D | ServicesInstantAppsCannotAccessTests.java | 47 assertNull(InstrumentationRegistry.getTargetContext().getSystemService( in cannotGetDevicePolicyManager() 53 assertNull(InstrumentationRegistry.getTargetContext().getSystemService( in cannotGetFingerprintManager() 59 assertNull(InstrumentationRegistry.getTargetContext().getSystemService( in cannotGetShortcutManager() 65 assertNull(InstrumentationRegistry.getTargetContext().getSystemService( in cannotGetUsbManager() 71 assertNull(InstrumentationRegistry.getTargetContext().getSystemService( in cannotGetWallpaperManager() 77 assertNull(InstrumentationRegistry.getTargetContext().getSystemService( in cannotGetWifiP2pManager() 83 assertNull(InstrumentationRegistry.getTargetContext().getSystemService( in cannotGetWifiManager() 89 assertNull(InstrumentationRegistry.getTargetContext().getSystemService( in cannotGetWifiAwareManager()
|
/cts/tests/tests/binder_ndk/src/android/binder/cts/ |
D | NdkBinderTest.java | 37 InstrumentationRegistry.getTargetContext(), NativeService.Local.class) in getLocalNativeService() 42 InstrumentationRegistry.getTargetContext(), JavaService.Local.class) in getLocalJavaService() 47 InstrumentationRegistry.getTargetContext(), NativeService.Remote.class) in getRemoteNativeService() 52 InstrumentationRegistry.getTargetContext(), JavaService.Remote.class) in getRemoteJavaService() 57 InstrumentationRegistry.getTargetContext(), NativeService.RemoteOld.class) in getRemoteOldNativeService()
|
/cts/tests/tests/os/src/android/os/health/cts/ |
D | SystemHealthManagerTest.java | 37 final Context context = getInstrumentation().getTargetContext(); in testTakeMyUidSnapshot() 48 final Context context = getInstrumentation().getTargetContext(); in testTakeUidSnapshotWithMe() 59 final Context context = getInstrumentation().getTargetContext(); in testTakeMyUidSnapshotWithSystem() 77 final Context context = getInstrumentation().getTargetContext(); in testTakeUidSnapshotsWithEmptyArray() 89 final Context context = getInstrumentation().getTargetContext(); in testTakeUidSnapshotsWithMe() 106 final Context context = getInstrumentation().getTargetContext(); in testTakeMyUidSnapshotsWithSystem()
|
/cts/hostsidetests/backup/SuccessNotificationApp/src/android/cts/backup/successnotificationapp/ |
D | SuccessNotificationTest.java | 19 import static androidx.test.InstrumentationRegistry.getTargetContext; 41 getTargetContext().getSharedPreferences(PREFS_FILE, Context.MODE_PRIVATE).edit().clear() in clearBackupSuccessNotificationsReceived() 47 assertTrue(getTargetContext().getSharedPreferences(PREFS_FILE, Context.MODE_PRIVATE) in verifyBackupSuccessNotificationReceivedForKeyValueApp() 53 assertTrue(getTargetContext().getSharedPreferences(PREFS_FILE, Context.MODE_PRIVATE) in verifyBackupSuccessNotificationReceivedForFullBackupApp()
|
/cts/tests/tests/graphics/src/android/graphics/cts/ |
D | TypefaceCustomFallbackBuilderTest.java | 50 final AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in createFullFamilyTypeface() 69 final AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testSingleFont_path() 84 final AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testSingleFont_ttc() 100 final AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testSingleFont_vf() 135 final AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testFamily_selectStyleByBuilder() 160 final AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testFamily_closestDefault() 179 final AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testUserFallback() 201 final AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testMaxCustomFallback() 214 final AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testMaxCustomFallback_exceed_limits() 236 final AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testUserFallbackOverLocaleFallback() [all …]
|
/cts/hostsidetests/appsecurity/test-apps/rro/OverlayApp/src/com/android/cts/overlay/app/ |
D | OverlayableTest.java | 68 private Context getTargetContext() throws Exception { in getTargetContext() method in OverlayableTest 69 return InstrumentationRegistry.getTargetContext().createPackageContext(TARGET_PACKAGE, 0); in getTargetContext() 76 Context context = getTargetContext(); in assertOverlayEnabled() 92 Context context = getTargetContext(); in testOverlayPolicyAll() 119 Context context = getTargetContext(); in testOverlayCodeNotLoaded() 132 Context context = getTargetContext(); in testSameSignatureNoOverlayableSucceeds() 158 assertTrue(InstrumentationRegistry.getTargetContext().getAssets().getOverlayablesToString( in testFrameworkDoesNotDefineOverlayable() 164 Context context = getTargetContext(); in testCannotOverlayAssets()
|
/cts/tests/tests/graphics/src/android/graphics/fonts/ |
D | FontFamilyTest.java | 43 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_SingleFont() 53 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_MultipleFont() 68 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_MultipleFont_overrideWeight() 83 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_MultipleFont_overrideItalic() 98 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_MultipleFont_SameStyle() 108 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_MultipleFont_SameStyle_overrideWeight() 118 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_MultipleFont_SameStyle_overrideItalic()
|
D | FontTest.java | 70 Context ctx = InstrumentationRegistry.getTargetContext(); in getTempFile() 153 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_buffer() 174 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_buffer_ttc() 196 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_buffer_vf() 220 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_buffer_override() 269 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_file() 295 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_file_ttc() 322 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_file_vf() 351 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_file_override() 409 AssetManager am = InstrumentationRegistry.getTargetContext().getAssets(); in testBuilder_fd() [all …]
|
/cts/tests/tests/appwidget/src/android/appwidget/cts/ |
D | AppWidgetDimensionsTest.java | 38 Resources resources = getInstrumentation().getTargetContext().getResources(); in backgroundRadius_shouldBePositive() 44 Resources resources = getInstrumentation().getTargetContext().getResources(); in backgroundRadius_shouldBeLessThanMaxRadius() 52 Resources resources = getInstrumentation().getTargetContext().getResources(); in innerRadius_shouldBeFixedComparedToBackgroundRadius()
|
D | AppWidgetTestCase.java | 67 return getInstrumentation().getTargetContext().getPackageManager() in hasAppWidgets() 114 assertEquals(getInstrumentation().getTargetContext().getPackageName(), in verifyInstalledProviders() 163 assertEquals(getInstrumentation().getTargetContext().getPackageName(), in verifyInstalledProviders() 187 return getInstrumentation().getTargetContext().getResources() in getNormalizedDimensionResource() 192 return getInstrumentation().getTargetContext().getResources().getInteger(resId); in getIntResource() 197 getInstrumentation().getTargetContext().getPackageName(), in getFirstWidgetComponent() 203 getInstrumentation().getTargetContext().getPackageName(), in getSecondWidgetComponent() 224 return (AppWidgetManager) getInstrumentation().getTargetContext() in getAppWidgetManager()
|
D | BlockingBroadcastReceiver.java | 43 InstrumentationRegistry.getTargetContext().unregisterReceiver(this); in onReceive() 57 InstrumentationRegistry.getTargetContext().registerReceiver( in register()
|
D | AppWidgetTest.java | 92 .getTargetContext().getCacheDir().getPath()); in setUpDexmaker() 98 Assume.assumeTrue(getInstrumentation().getTargetContext() in testInstantAppsCannotProvideAppWidgets() 106 Assume.assumeTrue(getInstrumentation().getTargetContext() in testInstantAppsCannotHostAppWidgets() 109 AppWidgetHost host = new AppWidgetHost(getInstrumentation().getTargetContext(), 0); in testInstantAppsCannotHostAppWidgets() 140 .getTargetContext().getSystemService(Context.USER_SERVICE); in testGetAppInstalledProvidersForCurrentUserNewAllProfiles() 161 AppWidgetHost host = new AppWidgetHost(getInstrumentation().getTargetContext(), 0); in testBindAppWidget() 199 AppWidgetHost host1 = new AppWidgetHost(getInstrumentation().getTargetContext(), 1); in testGetAppWidgetIdsForHost() 200 AppWidgetHost host2 = new AppWidgetHost(getInstrumentation().getTargetContext(), 2); in testGetAppWidgetIdsForHost() 243 AppWidgetHost host = new AppWidgetHost(getInstrumentation().getTargetContext(), 0); in testAppWidgetProviderCallbacks() 355 AppWidgetHost host = new AppWidgetHost(getInstrumentation().getTargetContext(), 0); in testTwoAppWidgetProviderCallbacks() [all …]
|
/cts/tests/app/src/android/app/cts/ |
D | SearchManagerTest.java | 33 intent.setClass(getInstrumentation().getTargetContext(), SearchManagerStubActivity.class); in setupActivity() 34 getInstrumentation().getTargetContext().startActivity(intent); in setupActivity() 65 Context context = getInstrumentation().getTargetContext(); in hasGlobalSearchActivity()
|
D | ActivityManagerFgsBgStartTest.java | 119 mTargetContext = mInstrumentation.getTargetContext(); in setUp() 172 WaitForBroadcast waiter = new WaitForBroadcast(mInstrumentation.getTargetContext()); in testFgsLocationStartFromBG() 196 waiter = new WaitForBroadcast(mInstrumentation.getTargetContext()); in testFgsLocationStartFromBG() 230 waiter = new WaitForBroadcast(mInstrumentation.getTargetContext()); in testFgsLocationStartFromBG() 279 WaitForBroadcast waiter = new WaitForBroadcast(mInstrumentation.getTargetContext()); in testFgsLocationStartFromBGTwoProcesses() 307 waiter = new WaitForBroadcast(mInstrumentation.getTargetContext()); in testFgsLocationStartFromBGTwoProcesses() 359 WaitForBroadcast waiter = new WaitForBroadcast(mInstrumentation.getTargetContext()); in testFgsLocationPendingIntent() 382 waiter = new WaitForBroadcast(mInstrumentation.getTargetContext()); in testFgsLocationPendingIntent() 396 waiter = new WaitForBroadcast(mInstrumentation.getTargetContext()); in testFgsLocationPendingIntent() 426 waiter = new WaitForBroadcast(mInstrumentation.getTargetContext()); in testFgsLocationPendingIntent() [all …]
|
/cts/tests/tests/preference/src/android/preference/cts/ |
D | TestUtils.java | 56 mContext = mInstrumentation.getTargetContext(); in TestUtils() 135 int resourceId = mInstrumentation.getTargetContext().getResources() in getStatusBarHeight() 138 mStatusBarHeight = mInstrumentation.getTargetContext().getResources() in getStatusBarHeight() 152 int resourceId = mInstrumentation.getTargetContext().getResources() in getNavigationBarHeight() 155 mNavigationBarHeight = mInstrumentation.getTargetContext().getResources() in getNavigationBarHeight()
|
/cts/tests/tests/packageinstaller/install_appop_default/src/android/packageinstaller/install_appop_default/cts/ |
D | ExternalSourcesInstantAppsTest.kt | 30 private val pm = InstrumentationRegistry.getTargetContext().packageManager 31 private val packageName = InstrumentationRegistry.getTargetContext().packageName
|
/cts/tests/tests/packageinstaller/install/src/android/packageinstaller/install/cts/ |
D | ExternalSourcesInstantAppsTest.kt | 30 private val pm = InstrumentationRegistry.getTargetContext().packageManager 31 private val packageName = InstrumentationRegistry.getTargetContext().packageName
|
/cts/tests/tests/packageinstaller/install_appop_denied/src/android/packageinstaller/install_appop_denied/cts/ |
D | ExternalSourcesInstantAppsTest.kt | 30 private val pm = InstrumentationRegistry.getTargetContext().packageManager 31 private val packageName = InstrumentationRegistry.getTargetContext().packageName
|
/cts/tests/inputmethod/src/android/view/inputmethod/cts/util/ |
D | EndToEndImeTestBase.java | 74 InstrumentationRegistry.getInstrumentation().getTargetContext() in verifyAppModeConsistency() 79 InstrumentationRegistry.getInstrumentation().getTargetContext() in verifyAppModeConsistency() 93 .setClass(InstrumentationRegistry.getInstrumentation().getTargetContext(), in showStateInitializeActivity()
|
/cts/tests/tests/view/src/android/view/cts/ |
D | ViewConfigurationTest.java | 76 Context context = InstrumentationRegistry.getTargetContext(); in testInstanceValues() 131 ViewConfiguration vc = ViewConfiguration.get(InstrumentationRegistry.getTargetContext()); 138 ViewConfiguration vc = ViewConfiguration.get(InstrumentationRegistry.getTargetContext()); in testGetScaledAmbiguousGestureMultiplier() 145 Context context = InstrumentationRegistry.getTargetContext(); in testGetMaximumDrawingCacheSize()
|
/cts/hostsidetests/backup/RestoreSessionTest/src/android/cts/backup/restoresessionapp/ |
D | BaseRestoreSessionAppTest.java | 19 import static androidx.test.InstrumentationRegistry.getTargetContext; 40 getTargetContext() in setUp()
|
/cts/tests/tests/provider/src/android/provider/cts/settings/ |
D | Settings_SystemTest.java | 52 final String packageName = InstrumentationRegistry.getTargetContext().getPackageName(); in setUp() 62 final String packageName = InstrumentationRegistry.getTargetContext().getPackageName(); in tearDown() 69 final ContentResolver cr = InstrumentationRegistry.getTargetContext().getContentResolver(); in testSystemSettings() 149 final ContentResolver cr = InstrumentationRegistry.getTargetContext().getContentResolver(); in testSystemSettingsRejectInvalidFontSizeScale() 177 final ContentResolver cr = InstrumentationRegistry.getTargetContext().getContentResolver(); in testGetDefaultValues()
|
/cts/tests/tests/media/src/android/media/cts/ |
D | MediaSessionManagerTest.java | 75 mContext = getInstrumentation().getTargetContext(); in setUp() 76 mAudioManager = (AudioManager) getInstrumentation().getTargetContext() in setUp() 78 mSessionManager = (MediaSessionManager) getInstrumentation().getTargetContext() in setUp() 120 MediaSession session = new MediaSession(getInstrumentation().getTargetContext(), TAG); in testOnMediaKeyEventSessionChangedListener() 128 Utils.assertMediaPlaybackStarted(getInstrumentation().getTargetContext()); in testOnMediaKeyEventSessionChangedListener() 156 MediaSession session = new MediaSession(getInstrumentation().getTargetContext(), TAG); in testOnMediaKeyEventDispatchedListener() 164 Utils.assertMediaPlaybackStarted(getInstrumentation().getTargetContext()); in testOnMediaKeyEventDispatchedListener() 172 assertEquals(getInstrumentation().getTargetContext().getPackageName(), in testOnMediaKeyEventDispatchedListener() 226 Context context = getInstrumentation().getTargetContext(); in testSetOnVolumeKeyLongPressListener() 270 session = new MediaSession(getInstrumentation().getTargetContext(), TAG); in testSetOnMediaKeyListener() [all …]
|
/cts/hostsidetests/backup/ProfileKeyValueApp/src/android.cts.backup.profilekeyvalueapp/ |
D | ProfileKeyValueBackupRestoreTest.java | 19 import static androidx.test.InstrumentationRegistry.getTargetContext; 46 Context context = getTargetContext(); in setUp()
|
/cts/libs/install/src/com/android/cts/install/lib/ |
D | InstallUtils.java | 86 Context context = InstrumentationRegistry.getTargetContext(); in getInstalledVersion() 120 Context context = InstrumentationRegistry.getTargetContext(); in waitForSession() 157 Context context = InstrumentationRegistry.getTargetContext(); in getPackageInfo() 170 return InstrumentationRegistry.getTargetContext().getPackageManager().getPackageInstaller(); in getPackageInstaller() 271 Context context = InstrumentationRegistry.getTargetContext(); in processUserData() 320 Context context = InstrumentationRegistry.getTargetContext(); in getUserDataVersion() 376 Context context = InstrumentationRegistry.getTargetContext(); in isOnlyInstalledForUser()
|