/platform_testing/libraries/collectors-helper/memory/test/src/com/android/helpers/tests/ |
D | GarbageCollectionHelperTest.java | 43 private @Mock UiDevice mUiDevice; field in GarbageCollectionHelperTest 60 }).when(mUiDevice).executeShellCommand(any()); in setUp() 71 verifyZeroInteractions(mUiDevice); in testNoSetUp() 82 InOrder inOrder = inOrder(mUiDevice); in testOneAppToGc() 83 inOrder.verify(mUiDevice).executeShellCommand("pidof package.name1"); in testOneAppToGc() 84 inOrder.verify(mUiDevice).executeShellCommand("kill -10 1"); in testOneAppToGc() 95 InOrder inOrder = inOrder(mUiDevice); in testMultipleAppsToGc() 96 inOrder.verify(mUiDevice).executeShellCommand("pidof package.name1"); in testMultipleAppsToGc() 97 inOrder.verify(mUiDevice).executeShellCommand("kill -10 1"); in testMultipleAppsToGc() 98 inOrder.verify(mUiDevice).executeShellCommand("pidof package.name2"); in testMultipleAppsToGc() [all …]
|
/platform_testing/libraries/collectors-helper/memory/src/com/android/helpers/ |
D | GarbageCollectionHelper.java | 40 private UiDevice mUiDevice; field in GarbageCollectionHelper 49 mUiDevice = initUiDevice(); in setUp() 72 if (mProcessNames == null || mUiDevice == null) { in garbageCollect() 80 String pidofOutput = mUiDevice.executeShellCommand( in garbageCollect() 83 mUiDevice.executeShellCommand(String.format(GC_CMD, pidofOutput)); in garbageCollect()
|
D | ProcessShowmapHelper.java | 63 private UiDevice mUiDevice; field in ProcessShowmapHelper 78 mUiDevice = UiDevice.getInstance(InstrumentationRegistry.getInstrumentation()); in setUp() 139 if (processNames == null || mUiDevice == null) { in sampleMemoryOfProcesses() 160 String pidofOutput = mUiDevice.executeShellCommand( in sampleMemory() 171 showmapOutput = mUiDevice.executeShellCommand(String.format(SHOWMAP_CMD, pid)); in sampleMemory()
|
D | DumpsysMeminfoHelper.java | 83 private UiDevice mUiDevice; field in DumpsysMeminfoHelper 94 mUiDevice = UiDevice.getInstance(InstrumentationRegistry.getInstrumentation()); in startCollecting() 118 String pidStr = mUiDevice.executeShellCommand(String.format(PIDOF_CMD, processName)); in getRawDumpsysMeminfo() 122 return mUiDevice.executeShellCommand(String.format(DUMPSYS_MEMINFO_CMD, pidStr)); in getRawDumpsysMeminfo()
|
D | ShowmapSnapshotHelper.java | 57 private UiDevice mUiDevice; field in ShowmapSnapshotHelper 70 mUiDevice = UiDevice.getInstance(InstrumentationRegistry.getInstrumentation()); in setUp() 193 mUiDevice.executeShellCommand(String.format(DROP_CACHES_CMD, cacheOption)); in dropCache() 207 String pidofOutput = mUiDevice.executeShellCommand(String.format(PIDOF_CMD, processName)); in getPids() 232 return mUiDevice.executeShellCommand(String.format(SHOWMAP_CMD, pid)); in execShowMap() 331 String psOutput = mUiDevice.executeShellCommand(ALL_PROCESSES_CMD); in getAllProcessNames()
|
D | FreeMemHelper.java | 64 private UiDevice mUiDevice; field in FreeMemHelper 68 mUiDevice = UiDevice.getInstance(InstrumentationRegistry.getInstrumentation()); in startCollecting() 81 memInfo = mUiDevice.executeShellCommand(PROC_MEMINFO); in getMetrics() 126 processInfoStr = mUiDevice.executeShellCommand(processDumpSysMemInfo); in getMetrics()
|
/platform_testing/libraries/health/rules/tests/src/android/platform/test/rule/ |
D | UnlockScreenRuleTest.java | 86 private UiDevice mUiDevice; field in UnlockScreenRuleTest.TestableUnlockScreenRule 91 mUiDevice = Mockito.mock(UiDevice.class); in TestableUnlockScreenRule() 99 when(mUiDevice.isScreenOn()).thenReturn(mIsScreenOn); in getUiDevice() 100 when(mUiDevice.hasObject(SCREEN_LOCK)).thenReturn(!mIsUnlocked); in getUiDevice() 104 return mUiDevice; in getUiDevice()
|
D | NaturalOrientationRuleTest.java | 57 private UiDevice mUiDevice; field in NaturalOrientationRuleTest.TestableNaturalOrientationRule 60 mUiDevice = Mockito.mock(UiDevice.class); in TestableNaturalOrientationRule() 65 return mUiDevice; in getUiDevice()
|
D | PressHomeRuleTest.java | 84 private UiDevice mUiDevice; field in PressHomeRuleTest.TestablePressHomeRule 88 mUiDevice = Mockito.mock(UiDevice.class); in TestablePressHomeRule() 99 return mUiDevice; in getUiDevice()
|
/platform_testing/libraries/collectors-helper/jank/test/src/com/android/helpers/ |
D | JankCollectionHelperTest.java | 88 private @Mock UiDevice mUiDevice; field in JankCollectionHelperTest 95 when(mHelper.getDevice()).thenReturn(mUiDevice); in setUp() 296 when(mUiDevice.executeShellCommand(cmd)).thenThrow(new RuntimeException()); in testCollect_delayExceptions_onReset() 306 InOrder inOrder = inOrder(mUiDevice); in testCollect_delayExceptions_onReset() 307 inOrder.verify(mUiDevice) in testCollect_delayExceptions_onReset() 309 inOrder.verify(mUiDevice) in testCollect_delayExceptions_onReset() 311 inOrder.verify(mUiDevice) in testCollect_delayExceptions_onReset() 324 when(mUiDevice.executeShellCommand(cmd)).thenThrow(new RuntimeException()); in testCollect_delayExceptions_onGet() 335 InOrder inOrder = inOrder(mUiDevice); in testCollect_delayExceptions_onGet() 336 inOrder.verify(mUiDevice) in testCollect_delayExceptions_onGet() [all …]
|
D | SfStatsCollectionHelperTest.java | 130 private @Mock UiDevice mUiDevice; field in SfStatsCollectionHelperTest 137 when(mHelper.getDevice()).thenReturn(mUiDevice); in setUp() 285 when(mUiDevice.executeShellCommand(SFSTATS_COMMAND_ENABLE_AND_CLEAR)).thenReturn(""); in mockEnableAndClearCommand() 289 when(mUiDevice.executeShellCommand(SFSTATS_COMMAND_DUMP)).thenReturn(SFSTATS_DUMP); in mockDumpCommand() 293 when(mUiDevice.executeShellCommand(SFSTATS_COMMAND_DISABLE_AND_CLEAR)).thenReturn(""); in mockDisableAndClearCommand()
|
D | BinderCollectionHelperTest.java | 44 private @Mock UiDevice mUiDevice; field in BinderCollectionHelperTest 94 when(mHelper.getDevice()).thenReturn(mUiDevice); in setUp()
|
/platform_testing/libraries/launcher-helper/src/android/support/test/launcherhelper/ |
D | LauncherStrategyFactory.java | 34 private UiDevice mUiDevice; field in LauncherStrategyFactory 40 mUiDevice = uiDevice; in LauncherStrategyFactory() 96 String launcherPkg = mUiDevice.getLauncherPackageName(); in getLauncherStrategy() 100 strategy.setUiDevice(mUiDevice); in getLauncherStrategy()
|
/platform_testing/libraries/collectors-helper/power/test/src/com/android/helpers/ |
D | PwrStatsUtilHelperTest.java | 41 private @Mock UiDevice mUiDevice; field in PwrStatsUtilHelperTest
|