Commit a2a05c66 authored by Ted Choc's avatar Ted Choc Committed by Commit Bot

Further deflake PopupTest#testPopupWindowsAppearWhenAllowed

This removes the other check that ensures a specific number of
infobars isn't showing.  This could be breaking if the translate
infobar showed up.

Stack:
java.lang.AssertionError: Criteria not met in allotted time.
	at org.junit.Assert.fail(Assert.java:88)
	at org.junit.Assert.assertTrue(Assert.java:41)
	at org.chromium.content.browser.test.util.CriteriaHelper.pollInstrumentationThread(CriteriaHelper.java:93)
	at org.chromium.content.browser.test.util.CriteriaHelper.pollUiThread(CriteriaHelper.java:172)
	at org.chromium.chrome.browser.PopupTest.testPopupWindowsAppearWhenAllowed(PopupTest.java:178)

BUG=771103

Change-Id: If439b42e6d0f63fa61cd75ea48bddb2e42571994
Reviewed-on: https://chromium-review.googlesource.com/1101830Reviewed-by: default avatarDavid Trainor <dtrainor@chromium.org>
Commit-Queue: Ted Choc <tedchoc@chromium.org>
Cr-Commit-Position: refs/heads/master@{#567702}
parent cda30669
......@@ -175,13 +175,10 @@ public class PopupTest {
// Document mode popups appear slowly and sequentially to prevent Android from throwing them
// away, so use a long timeout. http://crbug.com/498920.
CriteriaHelper.pollUiThread(new Criteria() {
@Override
public boolean isSatisfied() {
if (getNumInfobarsShowing() != 0) return false;
return TextUtils.equals("Two", selector.getCurrentTab().getTitle());
}
}, 7500, CriteriaHelper.DEFAULT_POLLING_INTERVAL);
CriteriaHelper.pollUiThread(
Criteria.equals("Two", () -> selector.getCurrentTab().getTitle()), 7500,
CriteriaHelper.DEFAULT_POLLING_INTERVAL);
waitForNoInfoBarOfType(InfoBarIdentifier.POPUP_BLOCKED_INFOBAR_DELEGATE_MOBILE);
Assert.assertEquals(3, selector.getTotalTabCount());
int currentTabId = selector.getCurrentTab().getId();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment