Commit 42fb7748 authored by Donn Denman's avatar Donn Denman Committed by Commit Bot

[TTS] Fix flaky test hiding the FindInPageOverlay.

The testTriggeringContextualSearchHidesFindInPageOverlay has been
very flaky recently, and it looks like the problem is due to clicks
in the content not triggering Contextual Search.  There's probably
a race condition between scrolling to put the word to click into
view and scrolling for the Find target.  The fix is to not type
any Find target to avoid the scroll.

BUG=765462

Change-Id: I007f7fa986e2528d7b7f9a4829be08c566572433
Reviewed-on: https://chromium-review.googlesource.com/742147Reviewed-by: default avatarTheresa <twellington@chromium.org>
Commit-Queue: Donn Denman <donnd@chromium.org>
Cr-Commit-Position: refs/heads/master@{#512581}
parent 889e6d27
......@@ -3219,8 +3219,8 @@ public class ContextualSearchManagerTest {
}
});
KeyUtils.singleKeyEventView(InstrumentationRegistry.getInstrumentation(),
mActivityTestRule.getActivity().findViewById(R.id.find_query), KeyEvent.KEYCODE_T);
// Don't type anything to Find because that may cause scrolling which makes clicking in the
// page flaky.
View findToolbar = mActivityTestRule.getActivity().findViewById(R.id.find_toolbar);
Assert.assertTrue(findToolbar.isShown());
......
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