diff options
author | Owen Lin <> | 2009-04-03 16:23:56 -0700 |
---|---|---|
committer | The Android Open Source Project <initial-contribution@android.com> | 2009-04-03 16:23:56 -0700 |
commit | 7a98363ea167e59a335fe4c832ceee3562bb2c59 (patch) | |
tree | 0d08e4e6a76d7e0648ebefe75bea357fa691f6cb /tests | |
parent | 101d528d59f447847d5c6b7578642132c2b76f4f (diff) | |
download | packages_apps_LegacyCamera-7a98363ea167e59a335fe4c832ceee3562bb2c59.zip packages_apps_LegacyCamera-7a98363ea167e59a335fe4c832ceee3562bb2c59.tar.gz packages_apps_LegacyCamera-7a98363ea167e59a335fe4c832ceee3562bb2c59.tar.bz2 |
AI 144532: Change the tests' package name to be identical to its path.
Automated import of CL 144532
Diffstat (limited to 'tests')
-rw-r--r-- | tests/AndroidManifest.xml | 13 | ||||
-rw-r--r-- | tests/src/com/android/camera/CameraLaunchPerformance.java | 8 | ||||
-rwxr-xr-x | tests/src/com/android/camera/CameraStressTestRunner.java | 7 | ||||
-rwxr-xr-x | tests/src/com/android/camera/stress/ImageCapture.java | 35 | ||||
-rwxr-xr-x | tests/src/com/android/camera/stress/SwitchPreview.java | 37 |
5 files changed, 49 insertions, 51 deletions
diff --git a/tests/AndroidManifest.xml b/tests/AndroidManifest.xml index 1b7abd2..54cc132 100644 --- a/tests/AndroidManifest.xml +++ b/tests/AndroidManifest.xml @@ -22,13 +22,16 @@ </application> <instrumentation android:name="CameraLaunchPerformance" - android:targetPackage="com.android.camera" - android:label="Camera Launch Performance"> + android:targetPackage="com.android.camera" + android:label="Camera Launch Performance"> </instrumentation> <instrumentation android:name=".CameraStressTestRunner" - android:targetPackage="com.android.camera" - android:label="Camera Stress Test InstrumentationRunner"> - </instrumentation> + android:targetPackage="com.android.camera" + android:label="Camera Stress Test InstrumentationRunner"> + </instrumentation> + <instrumentation android:name="android.test.InstrumentationTestRunner" + android:targetPackage="com.android.camera" + android:label="Tests for Camera application."/> </manifest> diff --git a/tests/src/com/android/camera/CameraLaunchPerformance.java b/tests/src/com/android/camera/CameraLaunchPerformance.java index 8c76f00..1b11136 100644 --- a/tests/src/com/android/camera/CameraLaunchPerformance.java +++ b/tests/src/com/android/camera/CameraLaunchPerformance.java @@ -14,19 +14,17 @@ * limitations under the License. */ -package com.android.camera.tests; +package com.android.camera; import android.app.Activity; -import android.test.LaunchPerformanceBase; import android.os.Bundle; - -import java.util.Map; +import android.test.LaunchPerformanceBase; /** * Instrumentation class for Camera launch performance testing. */ public class CameraLaunchPerformance extends LaunchPerformanceBase { - + public static final String LOG_TAG = "CameraLaunchPerformance"; public CameraLaunchPerformance() { diff --git a/tests/src/com/android/camera/CameraStressTestRunner.java b/tests/src/com/android/camera/CameraStressTestRunner.java index e34204c..7949c48 100755 --- a/tests/src/com/android/camera/CameraStressTestRunner.java +++ b/tests/src/com/android/camera/CameraStressTestRunner.java @@ -14,12 +14,13 @@ * limitations under the License. */ -package com.android.camera.tests; +package com.android.camera; + +import com.android.camera.stress.ImageCapture; +import com.android.camera.stress.SwitchPreview; import android.test.InstrumentationTestRunner; import android.test.InstrumentationTestSuite; -import com.android.camera.tests.stress.SwitchPreview; -import com.android.camera.tests.stress.ImageCapture; import junit.framework.TestSuite; diff --git a/tests/src/com/android/camera/stress/ImageCapture.java b/tests/src/com/android/camera/stress/ImageCapture.java index dbb1f64..69deef4 100755 --- a/tests/src/com/android/camera/stress/ImageCapture.java +++ b/tests/src/com/android/camera/stress/ImageCapture.java @@ -14,20 +14,19 @@ * limitations under the License. */ -package com.android.camera.tests.stress; +package com.android.camera.stress; + +import com.android.camera.Camera; -import android.app.Activity; import android.app.Instrumentation; import android.test.ActivityInstrumentationTestCase2; +import android.test.suitebuilder.annotation.LargeTest; import android.util.Log; import android.view.KeyEvent; -import android.test.suitebuilder.annotation.LargeTest; - -import com.android.camera.Camera; /** * Junit / Instrumentation test case for camera test - * + * */ public class ImageCapture extends ActivityInstrumentationTestCase2 <Camera> { @@ -39,20 +38,20 @@ public class ImageCapture extends ActivityInstrumentationTestCase2 <Camera> { private static final long WAIT_FOR_PREVIEW = 1000; //1 seconds public ImageCapture() { - super("com.android.camera", Camera.class); + super("com.android.camera", Camera.class); } - - @Override - protected void setUp() throws Exception { + + @Override + protected void setUp() throws Exception { getActivity(); - super.setUp(); + super.setUp(); } - - @Override - protected void tearDown() throws Exception { - super.tearDown(); + + @Override + protected void tearDown() throws Exception { + super.tearDown(); } - + @LargeTest public void testImageCapture() { Instrumentation inst = getInstrumentation(); @@ -68,7 +67,7 @@ public class ImageCapture extends ActivityInstrumentationTestCase2 <Camera> { } assertTrue("testImageCapture", true); } - + @LargeTest public void testVideoCapture() { Instrumentation inst = getInstrumentation(); @@ -93,4 +92,4 @@ public class ImageCapture extends ActivityInstrumentationTestCase2 <Camera> { } } - + diff --git a/tests/src/com/android/camera/stress/SwitchPreview.java b/tests/src/com/android/camera/stress/SwitchPreview.java index c00e553..08cf143 100755 --- a/tests/src/com/android/camera/stress/SwitchPreview.java +++ b/tests/src/com/android/camera/stress/SwitchPreview.java @@ -14,45 +14,42 @@ * limitations under the License. */ -package com.android.camera.tests.stress; +package com.android.camera.stress; + +import com.android.camera.VideoCamera; -import android.app.Activity; import android.app.Instrumentation; import android.test.ActivityInstrumentationTestCase2; +import android.test.suitebuilder.annotation.LargeTest; import android.util.Log; import android.view.KeyEvent; -import android.test.suitebuilder.annotation.LargeTest; - -import com.android.camera.Camera; -import com.android.camera.VideoCamera; /** * Junit / Instrumentation test case for camera test - * + * */ - public class SwitchPreview extends ActivityInstrumentationTestCase2 <VideoCamera>{ private String TAG = "SwitchPreview"; private static final int TOTAL_NUMBER_OF_SWITCHING = 200; private static final long WAIT_FOR_PREVIEW = 2000; - - + + public SwitchPreview() { - super("com.android.camera", VideoCamera.class); + super("com.android.camera", VideoCamera.class); } - - @Override - protected void setUp() throws Exception { + + @Override + protected void setUp() throws Exception { getActivity(); super.setUp(); } - - @Override - protected void tearDown() throws Exception { + + @Override + protected void tearDown() throws Exception { getActivity().finish(); - super.tearDown(); + super.tearDown(); } - + @LargeTest public void testSwitchMode() { //Switching the video and the video recorder mode @@ -71,4 +68,4 @@ public class SwitchPreview extends ActivityInstrumentationTestCase2 <VideoCamera assertTrue("testSwitchMode",true); } } - + |