/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/row/ |
D | NotificationInfoTest.java | 117 private PackageManager mMockPackageManager; field in NotificationInfoTest 140 when(mMockPackageManager.getPackageInfo(eq(TEST_PACKAGE_NAME), anyInt())) in setUp() 144 when(mMockPackageManager.getApplicationInfo(eq(TEST_PACKAGE_NAME), anyInt())).thenReturn( in setUp() 148 when(mMockPackageManager.getPackageInfo(eq(TEST_SYSTEM_PACKAGE_NAME), anyInt())) in setUp() 150 when(mMockPackageManager.getPackageInfo(eq("android"), anyInt())) in setUp() 198 when(mMockPackageManager.getApplicationLabel(any())).thenReturn("App Name"); in testBindNotification_SetsTextApplicationName() 200 mMockPackageManager, in testBindNotification_SetsTextApplicationName() 222 when(mMockPackageManager.getApplicationIcon(any(ApplicationInfo.class))) in testBindNotification_SetsPackageIcon() 225 mMockPackageManager, in testBindNotification_SetsPackageIcon() 246 mMockPackageManager, in testBindNotification_noDelegate() [all …]
|
D | AppOpsInfoTest.java | 69 private final PackageManager mMockPackageManager = mock(PackageManager.class); field in AppOpsInfoTest 83 when(mMockPackageManager.getPackageInfo(eq(TEST_PACKAGE_NAME), anyInt())) in setUp() 87 when(mMockPackageManager.getApplicationInfo(anyString(), anyInt())).thenReturn( in setUp() 96 when(mMockPackageManager.getApplicationLabel(any())).thenReturn("App Name"); in testBindNotification_SetsTextApplicationName() 97 mAppOpsInfo.bindGuts(mMockPackageManager, null, mSbn, new ArraySet<>()); in testBindNotification_SetsTextApplicationName() 105 when(mMockPackageManager.getApplicationIcon(any(ApplicationInfo.class))) in testBindNotification_SetsPackageIcon() 107 mAppOpsInfo.bindGuts(mMockPackageManager, null, mSbn, new ArraySet<>()); in testBindNotification_SetsPackageIcon() 117 mAppOpsInfo.bindGuts(mMockPackageManager, (View v, String pkg, int uid, in testBindNotification_SetsOnClickListenerForSettings() 136 mAppOpsInfo.bindGuts(mMockPackageManager, (View v, String pkg, int uid, in testOk() 154 mAppOpsInfo.bindGuts(mMockPackageManager, null, mSbn, expectedOps); in testPrompt_camera() [all …]
|
/frameworks/opt/telephony/tests/telephonytests/src/android/telephony/ims/ |
D | ImsMmTelManagerTests.java | 47 IPackageManager.Stub mMockPackageManager; field in ImsMmTelManagerTests 63 doReturn(mMockPackageManager).when(mMockPackageManager).queryLocalInterface(anyString()); in setUp() 64 doReturn(true).when(mMockPackageManager).hasSystemFeature( in setUp() 67 mServiceManagerMockedServices.put("package", mMockPackageManager); in setUp()
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/ |
D | NotificationFilterTest.java | 73 private final IPackageManager mMockPackageManager = mock(IPackageManager.class); field in NotificationFilterTest 84 when(mMockPackageManager.checkUidPermission( in setUp() 88 when(mMockPackageManager.checkUidPermission( in setUp() 111 mMockPackageManager, in testShowNotificationEvenIfUnprovisioned_FalseIfNoExtra() 122 mMockPackageManager, in testShowNotificationEvenIfUnprovisioned_FalseIfNoPermission() 134 mMockPackageManager, in testShowNotificationEvenIfUnprovisioned_TrueIfHasPermissionAndExtra()
|
/frameworks/base/services/tests/servicestests/src/com/android/server/accounts/ |
D | AccountManagerServiceTest.java | 109 @Mock private PackageManager mMockPackageManager; field in AccountManagerServiceTest 135 when(mMockPackageManager.checkSignatures(anyInt(), anyInt())) in setUp() 141 when(mMockContext.getPackageManager()).thenReturn(mMockPackageManager); in setUp() 148 when(mMockPackageManager.getPackageInfo(anyString(), anyInt())).thenReturn(mPackageInfo); in setUp() 214 when(mMockPackageManager.getPackagesForUid(anyInt())).thenReturn(list); in testCheckAddAccount() 332 when(mMockPackageManager.getPackagesForUid(anyInt())).thenReturn(list); in testRemovedAccountSync() 375 when(mMockPackageManager.getPackagesForUid(anyInt())).thenReturn(list); in testPreNDatabaseMigration() 612 when(mMockPackageManager.resolveActivityAsUser( in testStartAddAccountSessionReturnWithInvalidIntent() 614 when(mMockPackageManager.checkSignatures( in testStartAddAccountSessionReturnWithInvalidIntent() 643 when(mMockPackageManager.resolveActivityAsUser( in testStartAddAccountSessionReturnWithValidIntent() [all …]
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/shared/plugins/ |
D | PluginManagerTest.java | 66 private PackageManager mMockPackageManager; field in PluginManagerTest 84 mMockPackageManager = mock(PackageManager.class); in setup() 95 return new PluginEnablerImpl(context, mMockPackageManager); in setup() 206 mContext.setMockPackageManager(mMockPackageManager); in testDisableIntent() 214 verify(mMockPackageManager).setComponentEnabledSetting(eq(testComponent), in testDisableIntent()
|
/frameworks/base/core/tests/coretests/src/com/android/internal/app/ |
D | ResolverListControllerTest.java | 64 @Mock private PackageManager mMockPackageManager; field in ResolverListControllerTest 77 when(mMockPackageManager.queryIntentServices(any(), anyInt())).thenReturn(services); in setUp() 83 when(mMockContext.getPackageManager()).thenReturn(mMockPackageManager); in setUp() 113 mController = new ResolverListController(mMockContext, mMockPackageManager, sendIntent, in reportChooserSelection()
|
/frameworks/base/tests/testables/src/android/testing/ |
D | TestableContext.java | 68 private PackageManager mMockPackageManager; field in TestableContext 93 mMockPackageManager = mock; in setMockPackageManager() 98 if (mMockPackageManager != null) { in getPackageManager() 99 return mMockPackageManager; in getPackageManager()
|
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/ |
D | TelephonyPermissionsTest.java | 79 private PackageManager mMockPackageManager; field in TelephonyPermissionsTest 612 when(mMockContext.getPackageManager()).thenReturn(mMockPackageManager); in setupMocksForDeviceIdentifiersErrorPath() 613 when(mMockPackageManager.getApplicationInfoAsUser(eq(PACKAGE), anyInt(), any())) in setupMocksForDeviceIdentifiersErrorPath()
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/collection/ |
D | NotificationDataTest.java | 108 private final IPackageManager mMockPackageManager = mock(IPackageManager.class); field in NotificationDataTest 120 when(mMockPackageManager.checkUidPermission( in setUp() 124 when(mMockPackageManager.checkUidPermission( in setUp()
|
/frameworks/base/tests/PackageWatchdog/src/com/android/server/ |
D | PackageWatchdogTest.java | 91 private PackageManager mMockPackageManager; field in PackageWatchdogTest 103 when(mSpyContext.getPackageManager()).thenReturn(mMockPackageManager); in setUp() 104 when(mMockPackageManager.getPackageInfo(anyString(), anyInt())).then(inv -> { in setUp()
|
/frameworks/base/services/tests/servicestests/src/com/android/server/pm/ |
D | BaseShortcutManagerTest.java | 160 return mMockPackageManager; in getPackageManager() 613 protected PackageManager mMockPackageManager; field in BaseShortcutManagerTest 754 mMockPackageManager = mock(PackageManager.class); in setUp() 950 }).when(mMockPackageManager).getResourcesForApplicationAsUser(anyString(), anyInt()); in setUpAppResources()
|