aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorJean Chalard <jchalard@google.com>2014-11-17 18:26:15 +0900
committerJean Chalard <jchalard@google.com>2014-11-20 13:57:01 +0900
commita2cb2f36a6b51f73602bd7e917c418657da0c973 (patch)
treeb0a035c7d26a84e3ac29e0f315863aedf1e663be /tests
parent7cca01aa1d5aa1c8b8f10117fd2d83a49c82bea5 (diff)
downloadlatinime-a2cb2f36a6b51f73602bd7e917c418657da0c973.tar.gz
latinime-a2cb2f36a6b51f73602bd7e917c418657da0c973.tar.xz
latinime-a2cb2f36a6b51f73602bd7e917c418657da0c973.zip
Make the typed word a SuggestedWordInfo
That allows to carry the language information in an accurate manner. Bug: 18063142 Change-Id: I0bca8981372ae10648274095b18b26a3686b762b
Diffstat (limited to 'tests')
-rw-r--r--tests/src/com/android/inputmethod/latin/SuggestedWordsTests.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/src/com/android/inputmethod/latin/SuggestedWordsTests.java b/tests/src/com/android/inputmethod/latin/SuggestedWordsTests.java
index 7a7edf031..f658d726b 100644
--- a/tests/src/com/android/inputmethod/latin/SuggestedWordsTests.java
+++ b/tests/src/com/android/inputmethod/latin/SuggestedWordsTests.java
@@ -89,9 +89,10 @@ public class SuggestedWordsTests extends AndroidTestCase {
public void testGetTypedWordInfoOrNull() {
final String TYPED_WORD = "typed";
+ final SuggestedWordInfo TYPED_WORD_INFO = createTypedWordInfo(TYPED_WORD);
final int NUMBER_OF_ADDED_SUGGESTIONS = 5;
final ArrayList<SuggestedWordInfo> list = new ArrayList<>();
- list.add(createTypedWordInfo(TYPED_WORD));
+ list.add(TYPED_WORD_INFO);
for (int i = 0; i < NUMBER_OF_ADDED_SUGGESTIONS; ++i) {
list.add(createCorrectionWordInfo(Integer.toString(i)));
}
@@ -99,7 +100,7 @@ public class SuggestedWordsTests extends AndroidTestCase {
// Make sure getTypedWordInfoOrNull() returns non-null object.
final SuggestedWords wordsWithTypedWord = new SuggestedWords(
list, null /* rawSuggestions */,
- TYPED_WORD,
+ TYPED_WORD_INFO,
false /* typedWordValid */,
false /* willAutoCorrect */,
false /* isObsoleteSuggestions */,