Merge "CTS: Fixed NotificationTest for watches, since they always suppress notifications" into stage-aosp-oc-cts-dev
diff --git a/hostsidetests/incident/src/com/android/server/cts/NotificationTest.java b/hostsidetests/incident/src/com/android/server/cts/NotificationTest.java
index 10a1b77..f91c8a7 100644
--- a/hostsidetests/incident/src/com/android/server/cts/NotificationTest.java
+++ b/hostsidetests/incident/src/com/android/server/cts/NotificationTest.java
@@ -29,6 +29,9 @@
* cts-tradefed run singleCommand cts-dev -d --module CtsIncidentHostTestCases
*/
public class NotificationTest extends ProtoDumpTestCase {
+ // These constants are those in PackageManager.
+ public static final String FEATURE_WATCH = "android.hardware.type.watch";
+
/**
* Tests that at least one notification is posted, and verify its properties are plausible.
*/
@@ -67,9 +70,13 @@
assertEquals(ZenMode.ZEN_MODE_OFF, zenProto.getZenMode());
assertEquals(0, zenProto.getEnabledActiveConditionsCount());
- assertEquals(0, zenProto.getSuppressedEffects());
- assertEquals(0, zenProto.getSuppressorsCount());
+
+ // b/64606626 Watches intentionally suppress notifications always
+ if (!getDevice().hasFeature(FEATURE_WATCH)) {
+ assertEquals(0, zenProto.getSuppressedEffects());
+ assertEquals(0, zenProto.getSuppressorsCount());
+ }
+
zenProto.getPolicy();
}
}
-