commit | 9397482a2d42671515c8f750b2cb19cee164cbd0 | [log] [tgz] |
---|---|---|
author | Julia Reynolds <juliacr@google.com> | Mon Mar 09 12:17:00 2020 -0400 |
committer | Julia Reynolds <juliacr@google.com> | Mon Mar 09 12:17:00 2020 -0400 |
tree | 9f3b5423b6a1c92ed54b892bde9693ba1d4f2478 | |
parent | e2511d7c4e899dad1cadb91979a175954eda4019 [diff] |
Reduce (fix?) flakiness in dnd test Provide time for an asynchronous call to finish Test: this Fixes: 149240922 Change-Id: I2eb4e6e64660850c96c65ec352b334b302f4f9d8
diff --git a/tests/app/src/android/app/cts/NotificationManagerTest.java b/tests/app/src/android/app/cts/NotificationManagerTest.java index 0c4d6fe..459e01b 100644 --- a/tests/app/src/android/app/cts/NotificationManagerTest.java +++ b/tests/app/src/android/app/cts/NotificationManagerTest.java
@@ -825,6 +825,8 @@ mNotificationManager.setAutomaticZenRuleState(id1, onCondition1); mNotificationManager.setAutomaticZenRuleState(id2, onCondition2); + Thread.sleep(300); // wait for rules to be applied - it's done asynchronously + mRuleIds.add(id1); mRuleIds.add(id2); assertExpectedDndState(INTERRUPTION_FILTER_PRIORITY);