aboutsummaryrefslogtreecommitdiffstats
path: root/tests/src
diff options
context:
space:
mode:
authorTadashi G. Takaoka <takaoka@google.com>2012-02-07 05:46:05 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2012-02-07 05:46:05 -0800
commit29742cfc83f7cb9d1352be46e11a31fa537fef8a (patch)
tree848e3ef9bab4a685579fcec051f52df4cbf5ad9b /tests/src
parent870c9acce30d83ff3a078de70f3c7e90493e15c7 (diff)
parentc217dc9237e5d1e1e721b9007139d771dcb41145 (diff)
downloadlatinime-29742cfc83f7cb9d1352be46e11a31fa537fef8a.tar.gz
latinime-29742cfc83f7cb9d1352be46e11a31fa537fef8a.tar.xz
latinime-29742cfc83f7cb9d1352be46e11a31fa537fef8a.zip
am c217dc92: Convert one letter Key.outputText to Key.code
* commit 'c217dc9237e5d1e1e721b9007139d771dcb41145': Convert one letter Key.outputText to Key.code
Diffstat (limited to 'tests/src')
-rw-r--r--tests/src/com/android/inputmethod/keyboard/internal/KeySpecParserTests.java12
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/src/com/android/inputmethod/keyboard/internal/KeySpecParserTests.java b/tests/src/com/android/inputmethod/keyboard/internal/KeySpecParserTests.java
index 429e16d5f..07f5848b2 100644
--- a/tests/src/com/android/inputmethod/keyboard/internal/KeySpecParserTests.java
+++ b/tests/src/com/android/inputmethod/keyboard/internal/KeySpecParserTests.java
@@ -109,6 +109,10 @@ public class KeySpecParserTests extends AndroidTestCase {
"@", null, ICON_UNDEFINED, '@');
assertParser("Single escaped at", "\\@",
"@", null, ICON_UNDEFINED, '@');
+ assertParser("Single output text letter", "a|a",
+ "a", null, ICON_UNDEFINED, 'a');
+ assertParser("Single surrogate pair outputText", "G Clef|" + PAIR1,
+ "G Clef", null, ICON_UNDEFINED, CODE1);
assertParser("Single letter with outputText", "a|abc",
"a", "abc", ICON_UNDEFINED, Keyboard.CODE_OUTPUT_TEXT);
assertParser("Single letter with surrogate outputText", "a|" + SURROGATE1,
@@ -132,10 +136,10 @@ public class KeySpecParserTests extends AndroidTestCase {
"a", "a@c", ICON_UNDEFINED, Keyboard.CODE_OUTPUT_TEXT);
assertParser("Single letter with escaped at outputText", "a|\\@bc",
"a", "@bc", ICON_UNDEFINED, Keyboard.CODE_OUTPUT_TEXT);
- assertParser("Single escaped escape with outputText", "\\\\|\\\\",
- "\\", "\\", ICON_UNDEFINED, Keyboard.CODE_OUTPUT_TEXT);
- assertParser("Single escaped bar with outputText", "\\||\\|",
- "|", "|", ICON_UNDEFINED, Keyboard.CODE_OUTPUT_TEXT);
+ assertParser("Single escaped escape with single outputText", "\\\\|\\\\",
+ "\\", null, ICON_UNDEFINED, '\\');
+ assertParser("Single escaped bar with single outputText", "\\||\\|",
+ "|", null, ICON_UNDEFINED, '|');
assertParser("Single letter with code", "a|" + CODE_SETTINGS,
"a", null, ICON_UNDEFINED, mCodeSettings);
}