summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJaesung Chung <jaesung@google.com>2017-10-20 01:05:21 +0900
committerJaesung Chung <jaesung@google.com>2017-10-20 01:19:19 +0000
commit07bbd2b7ef9a05d4cb0fafc80ea9e817e0043443 (patch)
tree148a14238ea1664a796159a29ec473048b147826
parent10b5d0d22f2ecef14e2360c435b82bad3b66cb88 (diff)
downloadcts-07bbd2b7ef9a05d4cb0fafc80ea9e817e0043443.tar.gz
CtsViewTestCases: increase timeout
Increase timeout in several tests in CtsViewTestCases. Embedded devices are not fast enough to wait for completion within the previous timeout in some test cases because of the low performance CPU and no GPU on the board. Bug: 63580072 Test: bit of CtsViewTestCases on imx7d Change-Id: I18ab9fe27e0995b3bf971758a28dcd628758b1d6
-rw-r--r--tests/tests/view/src/android/view/animation/cts/AnimationTest.java2
-rw-r--r--tests/tests/view/src/android/view/cts/ChoreographerTest.java2
-rw-r--r--tests/tests/view/src/android/view/cts/PixelCopyViewProducerActivity.java2
-rw-r--r--tests/tests/view/src/android/view/cts/TextureViewCameraTest.java2
-rw-r--r--tests/tests/view/src/android/view/cts/TextureViewTest.java2
5 files changed, 5 insertions, 5 deletions
diff --git a/tests/tests/view/src/android/view/animation/cts/AnimationTest.java b/tests/tests/view/src/android/view/animation/cts/AnimationTest.java
index aac14e6cc38..d3bc8e0a127 100644
--- a/tests/tests/view/src/android/view/animation/cts/AnimationTest.java
+++ b/tests/tests/view/src/android/view/animation/cts/AnimationTest.java
@@ -77,7 +77,7 @@ public class AnimationTest {
/** It is defined in R.anim.decelerate_alpha */
private static final int DECELERATE_ALPHA_DURATION = 2000;
- private static final int CANCELATION_TIMEOUT = 1000;
+ private static final int CANCELATION_TIMEOUT = 5000;
private Instrumentation mInstrumentation;
private Activity mActivity;
diff --git a/tests/tests/view/src/android/view/cts/ChoreographerTest.java b/tests/tests/view/src/android/view/cts/ChoreographerTest.java
index e152d5b0d8c..a232b511182 100644
--- a/tests/tests/view/src/android/view/cts/ChoreographerTest.java
+++ b/tests/tests/view/src/android/view/cts/ChoreographerTest.java
@@ -82,7 +82,7 @@ public class ChoreographerTest {
// We expect the remaining callbacks to have been invoked once.
verify(addedCallback1, timeout(NOMINAL_VSYNC_PERIOD * 10).times(1)).run();
- verify(addedCallback2, times(1)).run();
+ verify(addedCallback2, timeout(NOMINAL_VSYNC_PERIOD * 10).times(1)).run();
verifyZeroInteractions(removedCallback);
// If we post a callback again, then it should be invoked again.
diff --git a/tests/tests/view/src/android/view/cts/PixelCopyViewProducerActivity.java b/tests/tests/view/src/android/view/cts/PixelCopyViewProducerActivity.java
index 925dd8e944a..ee1b921090f 100644
--- a/tests/tests/view/src/android/view/cts/PixelCopyViewProducerActivity.java
+++ b/tests/tests/view/src/android/view/cts/PixelCopyViewProducerActivity.java
@@ -108,7 +108,7 @@ public class PixelCopyViewProducerActivity extends Activity implements OnDrawLis
mCurrentOrientation = (mCurrentOrientation + 1) % ORIENTATIONS.length;
setRequestedOrientation(ORIENTATIONS[mCurrentOrientation]);
});
- waitForFirstDrawCompleted(3, TimeUnit.SECONDS);
+ waitForFirstDrawCompleted(10, TimeUnit.SECONDS);
return mCurrentOrientation != 0;
}
diff --git a/tests/tests/view/src/android/view/cts/TextureViewCameraTest.java b/tests/tests/view/src/android/view/cts/TextureViewCameraTest.java
index b909469308d..63d4d5e8e86 100644
--- a/tests/tests/view/src/android/view/cts/TextureViewCameraTest.java
+++ b/tests/tests/view/src/android/view/cts/TextureViewCameraTest.java
@@ -31,7 +31,7 @@ import org.junit.runner.RunWith;
@LargeTest
@RunWith(AndroidJUnit4.class)
public class TextureViewCameraTest {
- private static final long WAIT_TIMEOUT_IN_SECS = 10;
+ private static final long WAIT_TIMEOUT_IN_SECS = 30;
private TextureViewCameraActivity mActivity;
private int mNumberOfCameras;
diff --git a/tests/tests/view/src/android/view/cts/TextureViewTest.java b/tests/tests/view/src/android/view/cts/TextureViewTest.java
index c771c187819..d9b84a45c43 100644
--- a/tests/tests/view/src/android/view/cts/TextureViewTest.java
+++ b/tests/tests/view/src/android/view/cts/TextureViewTest.java
@@ -114,7 +114,7 @@ public class TextureViewTest {
private int waitForChange(Point point, int color)
throws InterruptedException, TimeoutException {
- for (int i = 0; i < 20; i++) {
+ for (int i = 0; i < 30; i++) {
int pixel = getPixel(point);
if (pixel != color) {
return pixel;