diff options
author | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | 2022-04-23 20:10:41 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2022-04-23 20:10:41 +0000 |
commit | 176880cc28c4d8b200f962125827dd8b80eabbdc (patch) | |
tree | ae5895897d88a43bca800e3ede7d3f183dfd81c9 | |
parent | 1e994803acca0226504fb3f71ec5dabe3f97b888 (diff) | |
parent | ac4a5a32e8ef0819b7b60bd4292f874865892942 (diff) | |
download | cts-176880cc28c4d8b200f962125827dd8b80eabbdc.tar.gz |
Merge "Snap for 8492999 from 13dafe7b220625bd11bac2a6902f7273f57e35ea to android12-tests-release" into android12-tests-releaseandroid-vts-12.0_r4
5 files changed, 14 insertions, 5 deletions
diff --git a/apps/CameraITS/tests/its_base_test.py b/apps/CameraITS/tests/its_base_test.py index afa0128785e..0bd10939ab2 100644 --- a/apps/CameraITS/tests/its_base_test.py +++ b/apps/CameraITS/tests/its_base_test.py @@ -176,6 +176,8 @@ class ItsBaseTest(base_test.BaseTestClass): # For some tablets the values are in constant forms such as ROTATION_90 if 'ROTATION_90' in landscape_val: landscape_val = '1' + elif 'ROTATION_0' in landscape_val: + landscape_val = '0' logging.debug('Changing the orientation to landscape mode.') self.tablet.adb.shell(['settings', 'put', 'system', 'user_rotation', landscape_val]) diff --git a/tests/tests/content/src/android/content/pm/cts/ResourcesHardeningTest.java b/tests/tests/content/src/android/content/pm/cts/ResourcesHardeningTest.java index 5385577c163..aafb494e4eb 100644 --- a/tests/tests/content/src/android/content/pm/cts/ResourcesHardeningTest.java +++ b/tests/tests/content/src/android/content/pm/cts/ResourcesHardeningTest.java @@ -290,7 +290,7 @@ public class ResourcesHardeningTest { private static class RemoteTest implements AutoCloseable { private static final int SPIN_SLEEP_MS = 500; - private static final long RESPONSE_TIMEOUT_MS = 60 * 1000; + private static final long RESPONSE_TIMEOUT_MS = 120 * 1000; private final ShellInstallSession mSession; private final String mTestName; diff --git a/tests/tests/graphics/src/android/graphics/cts/OpenGlEsDeqpLevelTest.java b/tests/tests/graphics/src/android/graphics/cts/OpenGlEsDeqpLevelTest.java index 1bb1106b973..323e32d154b 100644 --- a/tests/tests/graphics/src/android/graphics/cts/OpenGlEsDeqpLevelTest.java +++ b/tests/tests/graphics/src/android/graphics/cts/OpenGlEsDeqpLevelTest.java @@ -27,6 +27,7 @@ import androidx.test.ext.junit.runners.AndroidJUnit4; import androidx.test.filters.SmallTest; import androidx.test.platform.app.InstrumentationRegistry; +import com.android.compatibility.common.util.CddTest; import com.android.compatibility.common.util.PropertyUtil; import org.junit.Before; @@ -60,6 +61,7 @@ public class OpenGlEsDeqpLevelTest { } } + @CddTest(requirement = "7.1.4.1/C-2-3,C-2-4") @Test public void testOpenGlEsDeqpLevel() { assumeTrue( diff --git a/tests/tests/media/src/android/media/cts/MediaCodecTest.java b/tests/tests/media/src/android/media/cts/MediaCodecTest.java index be052ff6a4e..fd25703b4c3 100644 --- a/tests/tests/media/src/android/media/cts/MediaCodecTest.java +++ b/tests/tests/media/src/android/media/cts/MediaCodecTest.java @@ -2882,10 +2882,13 @@ public class MediaCodecTest extends AndroidTestCase { if (encCaps != null) { int bitrateMode = -1; List<Integer> candidates = Arrays.asList( - EncoderCapabilities.BITRATE_MODE_VBR, EncoderCapabilities.BITRATE_MODE_CBR, EncoderCapabilities.BITRATE_MODE_CQ, - EncoderCapabilities.BITRATE_MODE_CBR_FD); + EncoderCapabilities.BITRATE_MODE_CBR_FD, + // TODO: temporary workaround; + // isBitrateModeSupported(VBR) always returns true + // for video encoders in Android 12/12L + EncoderCapabilities.BITRATE_MODE_VBR); for (int candidate : candidates) { if (encCaps.isBitrateModeSupported(candidate)) { bitrateMode = candidate; diff --git a/tests/tests/view/src/android/view/cts/SystemGestureExclusionRectsTest.java b/tests/tests/view/src/android/view/cts/SystemGestureExclusionRectsTest.java index 25312e7c72c..e911e176f94 100644 --- a/tests/tests/view/src/android/view/cts/SystemGestureExclusionRectsTest.java +++ b/tests/tests/view/src/android/view/cts/SystemGestureExclusionRectsTest.java @@ -105,10 +105,12 @@ public class SystemGestureExclusionRectsTest { final CountDownLatch doneAnimating = new CountDownLatch(1); final Consumer<List<Rect>> vtoListener = results::add; + int[] location = new int[2]; mActivityRule.runOnUiThread(() -> { final View v = activity.findViewById(R.id.animating_view); final ViewTreeObserver vto = v.getViewTreeObserver(); + v.getLocationOnScreen(location); vto.addOnSystemGestureExclusionRectsChangedListener(vtoListener); v.setSystemGestureExclusionRects( @@ -133,8 +135,8 @@ public class SystemGestureExclusionRectsTest { assertTrue("rect had expected height", sizeRange.contains(first.height())); prev = first; } - - assertEquals("reached expected animated destination", prev.right, 35); + // Consideration of left system bar + assertEquals("reached expected animated destination", prev.right, 35 + location[0]); // Make sure we don't get any more callbacks after removing the VTO listener. // Capture values on the UI thread to avoid races. |