diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/AndroidManifest.xml | 2 | ||||
-rw-r--r-- | tests/src/com/android/inputmethod/latin/InputLogicTests.java | 13 |
2 files changed, 15 insertions, 0 deletions
diff --git a/tests/AndroidManifest.xml b/tests/AndroidManifest.xml index 38a2ecfeb..6bd46ccfb 100644 --- a/tests/AndroidManifest.xml +++ b/tests/AndroidManifest.xml @@ -17,6 +17,8 @@ <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.android.inputmethod.latin.tests"> + <uses-sdk android:minSdkVersion="16" android:targetSdkVersion="16" /> + <uses-permission android:name="android.permission.READ_CONTACTS" /> <application> diff --git a/tests/src/com/android/inputmethod/latin/InputLogicTests.java b/tests/src/com/android/inputmethod/latin/InputLogicTests.java index 7790299b0..38e57aaed 100644 --- a/tests/src/com/android/inputmethod/latin/InputLogicTests.java +++ b/tests/src/com/android/inputmethod/latin/InputLogicTests.java @@ -216,6 +216,19 @@ public class InputLogicTests extends InputTestsBase { assertEquals("manual pick then separator", EXPECTED_RESULT, mTextView.getText().toString()); } + public void testManualPickThenStripperThenPick() { + final String WORD_TO_TYPE = "this"; + final String STRIPPER = "\n"; + final String EXPECTED_RESULT = "this\nthis"; + type(WORD_TO_TYPE); + pickSuggestionManually(0, WORD_TO_TYPE); + type(STRIPPER); + type(WORD_TO_TYPE); + pickSuggestionManually(0, WORD_TO_TYPE); + assertEquals("manual pick then \\n then manual pick", EXPECTED_RESULT, + mTextView.getText().toString()); + } + public void testManualPickThenSpaceThenType() { final String WORD1_TO_TYPE = "this"; final String WORD2_TO_TYPE = " is"; |