aboutsummaryrefslogtreecommitdiffstats
path: root/tests/src/com/android/inputmethod/latin/BlueUnderlineTests.java
diff options
context:
space:
mode:
authorJean Chalard <jchalard@google.com>2012-11-20 20:14:13 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2012-11-20 20:14:13 -0800
commit40f7b43b3f0f2845cc005a901c911637c8c591ca (patch)
tree9809d98d977144e1b12b1cf304b9838ec1d2007f /tests/src/com/android/inputmethod/latin/BlueUnderlineTests.java
parente36af707c8a8705ebd19fcc359c51181f7ebd171 (diff)
parent82cc7349254e1ca3722ead1f108b6c53820432d5 (diff)
downloadlatinime-40f7b43b3f0f2845cc005a901c911637c8c591ca.tar.gz
latinime-40f7b43b3f0f2845cc005a901c911637c8c591ca.tar.xz
latinime-40f7b43b3f0f2845cc005a901c911637c8c591ca.zip
am 82cc7349: am b9385ff9: am cdbf6fb5: Merge "Correctly add double quote to the space strippers" into jb-mr1.1-dev
* commit '82cc7349254e1ca3722ead1f108b6c53820432d5': Correctly add double quote to the space strippers
Diffstat (limited to 'tests/src/com/android/inputmethod/latin/BlueUnderlineTests.java')
-rw-r--r--tests/src/com/android/inputmethod/latin/BlueUnderlineTests.java16
1 files changed, 16 insertions, 0 deletions
diff --git a/tests/src/com/android/inputmethod/latin/BlueUnderlineTests.java b/tests/src/com/android/inputmethod/latin/BlueUnderlineTests.java
index 02047cfc4..e2d669bf6 100644
--- a/tests/src/com/android/inputmethod/latin/BlueUnderlineTests.java
+++ b/tests/src/com/android/inputmethod/latin/BlueUnderlineTests.java
@@ -104,4 +104,20 @@ public class BlueUnderlineTests extends InputTestsBase {
final SpanGetter span = new SpanGetter(mTextView.getText(), SuggestionSpan.class);
assertNull("blue underline removed when cursor is moved", span.mSpan);
}
+
+ public void testComposingStopsOnSpace() {
+ final String STRING_TO_TYPE = "this ";
+ type(STRING_TO_TYPE);
+ sleep(DELAY_TO_WAIT_FOR_UNDERLINE);
+ // Simulate the onUpdateSelection() event
+ mLatinIME.onUpdateSelection(0, 0, STRING_TO_TYPE.length(), STRING_TO_TYPE.length(), -1, -1);
+ runMessages();
+ // Here the blue underline has been set. testBlueUnderline() is testing for this already,
+ // so let's not test it here again.
+ // Now simulate the user moving the cursor.
+ SpanGetter span = new SpanGetter(mTextView.getText(), UnderlineSpan.class);
+ assertNull("should not be composing, so should not have an underline span", span.mSpan);
+ span = new SpanGetter(mTextView.getText(), SuggestionSpan.class);
+ assertNull("should not be composing, so should not have an underline span", span.mSpan);
+ }
}