From cc2751ba03fad6af5da0a7b5d421963e040d690f Mon Sep 17 00:00:00 2001 From: Yuichiro Hanada Date: Thu, 5 Sep 2013 17:56:00 +0900 Subject: Make commitCurrentAutoCorrection asynchronous. Change-Id: Ida230ca4243347fb3ab9fda7de3a9a18f886cd1c --- tests/src/com/android/inputmethod/latin/InputTestsBase.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'tests/src/com/android/inputmethod/latin/InputTestsBase.java') diff --git a/tests/src/com/android/inputmethod/latin/InputTestsBase.java b/tests/src/com/android/inputmethod/latin/InputTestsBase.java index 0a1c4e963..da1fb6f0d 100644 --- a/tests/src/com/android/inputmethod/latin/InputTestsBase.java +++ b/tests/src/com/android/inputmethod/latin/InputTestsBase.java @@ -44,10 +44,12 @@ public class InputTestsBase extends ServiceTestCase { private static final String PREF_DEBUG_MODE = "debug_mode"; - // The message that sets the underline is posted with a 100 ms delay + // The message that sets the underline is posted with a 200 ms delay protected static final int DELAY_TO_WAIT_FOR_UNDERLINE = 200; - // The message that sets predictions is posted with a 100 ms delay + // The message that sets predictions is posted with a 200 ms delay protected static final int DELAY_TO_WAIT_FOR_PREDICTIONS = 200; + // The message that sets auto-corrections is posted within a 100 ms delay. + protected static final int DELAY_TO_WAIT_FOR_AUTOCORRECTION = 100; protected LatinIME mLatinIME; protected Keyboard mKeyboard; @@ -221,6 +223,7 @@ public class InputTestsBase extends ServiceTestCase { protected void type(final String stringToType) { for (int i = 0; i < stringToType.length(); i = stringToType.offsetByCodePoints(i, 1)) { type(stringToType.codePointAt(i)); + sleep(DELAY_TO_WAIT_FOR_AUTOCORRECTION); } } -- cgit v1.2.3-83-g751a