Commit Graph

2 Commits

Author SHA1 Message Date
czq
c841a4ae2a Add unit test for InputMethodBindingController
Also slightly modified InputMethodBindingController to make it
unit testable.

Bug: b/240359838

Test: atest com.android.server.inputmethod.InputMethodBindingControllerTest
Change-Id: I9cd7d1e33fc366369da0c46deec8172b4bbac0d4
2022-11-30 11:55:36 +08:00
Lan Wei
fd646fe8c0 Add unit tests for InputMethodManagerService
Injecting and mocking dependencies to InputMethodManagerService to make
it unit testable.

Add InputMethodManagerServiceTestBase base class to help unit test IMMS.

Add the first batch of unit tests in InputMethodManagerServiceWindowGainedFocusTest to cover the behavior of IMMS#startInputOrWindowGainedFocus(), which should help us catch any regressions caused by future changes to the code.

Bug: 240359838
Test: atest com.android.server.inputmethod.InputMethodManagerServiceWindowGainedFocusTest
Change-Id: Id61087f1e176738910f5acfe912f8682f727255c
2022-10-26 15:21:59 +08:00