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

Skip to content
Commit 67bf216d authored by Siarhei Vishniakou's avatar Siarhei Vishniakou
Browse files

InputDispatcherSingleWindowAnr: Send events via InputListener instead of injection

This test is flaky, but the flake is not reproducible locally.
The failure is happening because the injection times out, but it's not
clear why. In general, injection is only used for tests, and the primary
path of interest is the "notify" call into dispatcher, which is what's
used by the real hardware events.

In this CL, the test is refactored to use the "notifyMotion" calls into
dispatcher when trying to send the events. This is roughly equivalent to
the asynchronous injection.

This will make the test more realistic, and should remove the possible
racing between the injection timeout and the other ANR timeouts that are
being asserted.

If the test remains flaky after this, we should now get a different
failure, and this should hopefully help figure out the root cause.

Bug: 294547658
Test: TEST=inputflinger_tests; m $TEST && $ANDROID_HOST_OUT/nativetest64/$TEST/$TEST
Change-Id: Iced8b1830a1a10a3ae00280567246af7a3fcb572
parent d908f5a0
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