From e894f6a870d933529a6b3fb95b04c24b92a9682a Mon Sep 17 00:00:00 2001 From: Nataniel Borges Date: Tue, 28 Jan 2020 16:47:03 +0100 Subject: [PATCH] Reduce the number of rotations of flicker tests To reduce the flicker test time, reduce the tests to consider only: * Start test at 0 degrees * Start test at 90 degrees * Rotation tests from 0 to 90 degrees * Rotation tests from 90 to 0 degrees Also, execute each action a single time. Test: atest FlickerTest Change-Id: I5976cf950998a8150fd5a1b32f0f1432cd731ee1 --- .../com/android/server/wm/flicker/ChangeAppRotationTest.java | 2 +- .../android/server/wm/flicker/SeamlessAppRotationTest.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/FlickerTests/src/com/android/server/wm/flicker/ChangeAppRotationTest.java b/tests/FlickerTests/src/com/android/server/wm/flicker/ChangeAppRotationTest.java index 42cafd43f8bdf..5a66e805c575c 100644 --- a/tests/FlickerTests/src/com/android/server/wm/flicker/ChangeAppRotationTest.java +++ b/tests/FlickerTests/src/com/android/server/wm/flicker/ChangeAppRotationTest.java @@ -66,7 +66,7 @@ public class ChangeAppRotationTest extends FlickerTestBase { @Parameters(name = "{0}-{1}") public static Collection getParams() { int[] supportedRotations = - {Surface.ROTATION_0, Surface.ROTATION_90, Surface.ROTATION_270}; + {Surface.ROTATION_0, Surface.ROTATION_90}; Collection params = new ArrayList<>(); for (int begin : supportedRotations) { for (int end : supportedRotations) { diff --git a/tests/FlickerTests/src/com/android/server/wm/flicker/SeamlessAppRotationTest.java b/tests/FlickerTests/src/com/android/server/wm/flicker/SeamlessAppRotationTest.java index ae55a75d7e673..14e2629635751 100644 --- a/tests/FlickerTests/src/com/android/server/wm/flicker/SeamlessAppRotationTest.java +++ b/tests/FlickerTests/src/com/android/server/wm/flicker/SeamlessAppRotationTest.java @@ -65,7 +65,7 @@ public class SeamlessAppRotationTest extends FlickerTestBase { @Parameters(name = "{0}") public static Collection getParams() { int[] supportedRotations = - {Surface.ROTATION_0, Surface.ROTATION_90, Surface.ROTATION_270}; + {Surface.ROTATION_0, Surface.ROTATION_90}; Collection params = new ArrayList<>(); ArrayList testIntents = new ArrayList<>(); @@ -108,7 +108,7 @@ public class SeamlessAppRotationTest extends FlickerTestBase { super.runTransition( changeAppRotation(mIntent, intentId, InstrumentationRegistry.getContext(), - mUiDevice, mBeginRotation, mEndRotation).repeat(5).build()); + mUiDevice, mBeginRotation, mEndRotation).build()); } @Test