New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 765322 link

Starred by 0 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Dec 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 3
Type: Bug



Sign in to add a comment

ImeActivityTestRule.setUp() is flaky

Project Member Reported by rlanday@chromium.org, Sep 14 2017

Issue description

See discussion here:
https://chromium-review.googlesource.com/c/chromium/src/+/663202#message-7c07b96a893d5cba88af6f6e2b6a7f2aaf6ce2f9

C  369.849s Main  [FAIL] org.chromium.content.browser.input.ImeTest#testSelectActionBarClearedOnTappingOutsideInput:
C  369.849s Main  junit.framework.AssertionFailedError: input connection should not be null.
C  369.849s Main  	at junit.framework.Assert.fail(Assert.java:50)
C  369.849s Main  	at junit.framework.Assert.assertTrue(Assert.java:20)
C  369.849s Main  	at org.chromium.content.browser.test.util.CriteriaHelper.pollInstrumentationThread(CriteriaHelper.java:79)
C  369.849s Main  	at org.chromium.content.browser.test.util.CriteriaHelper.pollUiThread(CriteriaHelper.java:117)
C  369.849s Main  	at org.chromium.content.browser.test.util.CriteriaHelper.pollUiThread(CriteriaHelper.java:138)
C  369.849s Main  	at org.chromium.content.browser.input.ImeActivityTestRule.assertWaitForKeyboardStatus(ImeActivityTestRule.java:229)
C  369.849s Main  	at org.chromium.content.browser.input.ImeActivityTestRule.setUp(ImeActivityTestRule.java:105)
C  369.850s Main  	at org.chromium.content.browser.input.ImeTest.setUp(ImeTest.java:47)
C  369.850s Main  	at java.lang.reflect.Method.invokeNative(Native Method)
C  369.850s Main  	at java.lang.reflect.Method.invoke(Method.java:515)
 
I think the issue here is that ImeActivityTestRule.setUp() clicks a DOM node:
https://chromium.googlesource.com/chromium/src/+/041c0b075176fb9bca94fd67fc1b6053a4df2e1c/content/public/android/javatests/src/org/chromium/content/browser/input/ImeActivityTestRule.java#102

and then polls for the keyboard to appear:
https://chromium.googlesource.com/chromium/src/+/041c0b075176fb9bca94fd67fc1b6053a4df2e1c/content/public/android/javatests/src/org/chromium/content/browser/input/ImeActivityTestRule.java#105


This can take a variable amount of time, e.g. if the renderer thread is stalled. I can only find failures on the "Android Tests (dbg)" builder (perhaps because it's slower than the others):
https://test-results.appspot.com/dashboards/flakiness_dashboard.html#testType=content_shell_test_apk&tests=ImeTest

The only remedies I can think of are to either increase the timeout, or add RetryOnFailure to these tests.
Labels: -Pri-2 Pri-3
Status: Fixed (was: Assigned)
I don't think this is flaky anymore

Sign in to add a comment