Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b2119194 authored by Ming-Shin Lu's avatar Ming-Shin Lu
Browse files

Fix testGetSettingsContextOnDualDisplayContent flakiness (2)

This is the follow-up CL of [1].

The rare flakiness might happen if we verifying onConfigurationChanged
after placeImeContainer but not comes in time after invocation.

Also, using atLeastOnce might not precide since we don't clear the
previous invocation with Mockito.clearInvications() before the next
verification. Typically, there is only one onConfigurationChanged
happens on both IME container and WindowTokenClient side after
the IME container changed.

To make the test more robost, we can use
verify(..., timeOut(WAIT_TIMEOUT_MS)) with clearng the previous
invocation to improve the above cases.

[1]: Ia915362ff6d81cfb1eb39f426cbf41355c12fa05

Bug: 215874086
Test: Test: atest InputMethodMenuControllerTest#\
   testGetSettingsContextOnDualDisplayContent --rerun-until-failure 100

Change-Id: I50429e09f190bdbea873fc3c0d6128bb44bff321
parent ed0e1218
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment