From f338f8b50d276cfed2bafe6856792c675087ad15 Mon Sep 17 00:00:00 2001 From: Jean Chalard Date: Fri, 13 Apr 2012 17:38:16 +0900 Subject: [PATCH] Add a test for umlauts Change-Id: I2c15e9dc7a1cf846c92a1900d68f661aa70e77b9 --- ...ts.java => InputLogicTestsNonEnglish.java} | 20 ++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) rename tests/src/com/android/inputmethod/latin/{InputLogicFrenchTests.java => InputLogicTestsNonEnglish.java} (75%) diff --git a/tests/src/com/android/inputmethod/latin/InputLogicFrenchTests.java b/tests/src/com/android/inputmethod/latin/InputLogicTestsNonEnglish.java similarity index 75% rename from tests/src/com/android/inputmethod/latin/InputLogicFrenchTests.java rename to tests/src/com/android/inputmethod/latin/InputLogicTestsNonEnglish.java index 60a7b05a9..b2b9601b6 100644 --- a/tests/src/com/android/inputmethod/latin/InputLogicFrenchTests.java +++ b/tests/src/com/android/inputmethod/latin/InputLogicTestsNonEnglish.java @@ -16,7 +16,7 @@ package com.android.inputmethod.latin; -public class InputLogicFrenchTests extends InputTestsBase { +public class InputLogicTestsNonEnglish extends InputTestsBase { public void testAutoCorrectForFrench() { final String STRING_TO_TYPE = "irq "; @@ -54,4 +54,22 @@ public class InputLogicFrenchTests extends InputTestsBase { assertEquals("type word then type space then punctuation from strip twice for French", EXPECTED_RESULT, mTextView.getText().toString()); } + + public void testAutoCorrectForGerman() { + final String STRING_TO_TYPE = "unf "; + final String EXPECTED_RESULT = "und "; + changeLanguage("de"); + type(STRING_TO_TYPE); + assertEquals("simple auto-correct for German", EXPECTED_RESULT, + mTextView.getText().toString()); + } + + public void testAutoCorrectWithUmlautForGerman() { + final String STRING_TO_TYPE = "ueber "; + final String EXPECTED_RESULT = "über "; + changeLanguage("de"); + type(STRING_TO_TYPE); + assertEquals("auto-correct with umlaut for German", EXPECTED_RESULT, + mTextView.getText().toString()); + } }