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

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

Add tests for pointer stuck in TouchState

Add two tests that reproduce the conditions necessary for the pointer to
be stuck inside TouchState.

In both cases, this is caused by calling
synthesizeCancelationEventsForConnectionLocked without also changing the
TouchState. That makes TouchState and InputState out of sync.

Currently, this setup does not cause a crash, but rather, just drops
some of the touches unexpectedly.

These tests are added as documentation of the current behaviour. When
the situation is fixed in the future, the tests would need to be
updated. If we wanted the tests to fail, we could crash the dispatcher
whenever InputState detects an inconsistent stream. A similar solution
will be done eventually by enabling the InputVerifier for all outgoing
streams.

Bug: 281806933
Test: m inputflinger_tests && adb sync data && adb shell -t data/nativetest64/inputflinger_tests/inputflinger_tests
Change-Id: Iaa949f2aa8dd2a7db9e8fd8bb365430e805cda79
parent 463c17e1
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