Loading tests/AppLaunch/src/com/android/tests/applaunch/AppLaunch.java +13 −0 Original line number Diff line number Diff line Loading @@ -22,6 +22,7 @@ import android.app.ActivityManager.ProcessErrorStateInfo; import android.app.ActivityManagerNative; import android.app.IActivityManager; import android.app.IActivityManager.WaitResult; import android.app.UiAutomation; import android.content.Context; import android.content.Intent; import android.content.pm.PackageManager; Loading Loading @@ -72,6 +73,18 @@ public class AppLaunch extends InstrumentationTestCase { private Bundle mResult = new Bundle(); private Set<String> mRequiredAccounts; @Override protected void setUp() throws Exception { super.setUp(); getInstrumentation().getUiAutomation().setRotation(UiAutomation.ROTATION_FREEZE_0); } @Override protected void tearDown() throws Exception { getInstrumentation().getUiAutomation().setRotation(UiAutomation.ROTATION_UNFREEZE); super.tearDown(); } public void testMeasureStartUpTime() throws RemoteException, NameNotFoundException { InstrumentationTestRunner instrumentation = (InstrumentationTestRunner)getInstrumentation(); Loading tests/MemoryUsage/src/com/android/tests/memoryusage/MemoryUsageTest.java +13 −0 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ import android.app.ActivityManager.ProcessErrorStateInfo; import android.app.ActivityManager.RunningAppProcessInfo; import android.app.ActivityManagerNative; import android.app.IActivityManager; import android.app.UiAutomation; import android.content.Context; import android.content.Intent; import android.content.pm.PackageManager; Loading Loading @@ -67,6 +68,18 @@ public class MemoryUsageTest extends InstrumentationTestCase { private Set<String> mPersistentProcesses; private IActivityManager mAm; @Override protected void setUp() throws Exception { super.setUp(); getInstrumentation().getUiAutomation().setRotation(UiAutomation.ROTATION_FREEZE_0); } @Override protected void tearDown() throws Exception { getInstrumentation().getUiAutomation().setRotation(UiAutomation.ROTATION_UNFREEZE); super.tearDown(); } public void testMemory() { MemoryUsageInstrumentation instrumentation = (MemoryUsageInstrumentation) getInstrumentation(); Loading Loading
tests/AppLaunch/src/com/android/tests/applaunch/AppLaunch.java +13 −0 Original line number Diff line number Diff line Loading @@ -22,6 +22,7 @@ import android.app.ActivityManager.ProcessErrorStateInfo; import android.app.ActivityManagerNative; import android.app.IActivityManager; import android.app.IActivityManager.WaitResult; import android.app.UiAutomation; import android.content.Context; import android.content.Intent; import android.content.pm.PackageManager; Loading Loading @@ -72,6 +73,18 @@ public class AppLaunch extends InstrumentationTestCase { private Bundle mResult = new Bundle(); private Set<String> mRequiredAccounts; @Override protected void setUp() throws Exception { super.setUp(); getInstrumentation().getUiAutomation().setRotation(UiAutomation.ROTATION_FREEZE_0); } @Override protected void tearDown() throws Exception { getInstrumentation().getUiAutomation().setRotation(UiAutomation.ROTATION_UNFREEZE); super.tearDown(); } public void testMeasureStartUpTime() throws RemoteException, NameNotFoundException { InstrumentationTestRunner instrumentation = (InstrumentationTestRunner)getInstrumentation(); Loading
tests/MemoryUsage/src/com/android/tests/memoryusage/MemoryUsageTest.java +13 −0 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ import android.app.ActivityManager.ProcessErrorStateInfo; import android.app.ActivityManager.RunningAppProcessInfo; import android.app.ActivityManagerNative; import android.app.IActivityManager; import android.app.UiAutomation; import android.content.Context; import android.content.Intent; import android.content.pm.PackageManager; Loading Loading @@ -67,6 +68,18 @@ public class MemoryUsageTest extends InstrumentationTestCase { private Set<String> mPersistentProcesses; private IActivityManager mAm; @Override protected void setUp() throws Exception { super.setUp(); getInstrumentation().getUiAutomation().setRotation(UiAutomation.ROTATION_FREEZE_0); } @Override protected void tearDown() throws Exception { getInstrumentation().getUiAutomation().setRotation(UiAutomation.ROTATION_UNFREEZE); super.tearDown(); } public void testMemory() { MemoryUsageInstrumentation instrumentation = (MemoryUsageInstrumentation) getInstrumentation(); Loading