diff options
author | 2014-11-19 08:34:08 +0000 | |
---|---|---|
committer | 2014-11-19 08:34:08 +0000 | |
commit | 6cea754895872d208c8b6a3bc2f9c26d21746b33 (patch) | |
tree | 0cbbb7e16107500ff3a12172a7560fe70c1f5824 /tests/src/com/android/inputmethod/compat/SuggestionSpanUtilsTest.java | |
parent | 8833756d522e247f40b6824f642ee3f5a67e1086 (diff) | |
parent | fde0cce1037a635c34e55baa17424f8eff53b6da (diff) | |
download | latinime-6cea754895872d208c8b6a3bc2f9c26d21746b33.tar.gz latinime-6cea754895872d208c8b6a3bc2f9c26d21746b33.tar.xz latinime-6cea754895872d208c8b6a3bc2f9c26d21746b33.zip |
am fde0cce1: Merge "Remove the other deprecated constructor to SuggestedWords"
* commit 'fde0cce1037a635c34e55baa17424f8eff53b6da':
Remove the other deprecated constructor to SuggestedWords
Diffstat (limited to 'tests/src/com/android/inputmethod/compat/SuggestionSpanUtilsTest.java')
-rw-r--r-- | tests/src/com/android/inputmethod/compat/SuggestionSpanUtilsTest.java | 24 |
1 files changed, 14 insertions, 10 deletions
diff --git a/tests/src/com/android/inputmethod/compat/SuggestionSpanUtilsTest.java b/tests/src/com/android/inputmethod/compat/SuggestionSpanUtilsTest.java index 1c320db1c..7bbf965f9 100644 --- a/tests/src/com/android/inputmethod/compat/SuggestionSpanUtilsTest.java +++ b/tests/src/com/android/inputmethod/compat/SuggestionSpanUtilsTest.java @@ -102,11 +102,11 @@ public class SuggestionSpanUtilsTest extends AndroidTestCase { } public void testGetTextWithSuggestionSpan() { - final SuggestedWordInfo predicition1 = + final SuggestedWordInfo prediction1 = createWordInfo("Quality", SuggestedWordInfo.KIND_PREDICTION); - final SuggestedWordInfo predicition2 = + final SuggestedWordInfo prediction2 = createWordInfo("Speed", SuggestedWordInfo.KIND_PREDICTION); - final SuggestedWordInfo predicition3 = + final SuggestedWordInfo prediction3 = createWordInfo("Price", SuggestedWordInfo.KIND_PREDICTION); final SuggestedWordInfo typed = @@ -122,13 +122,15 @@ public class SuggestionSpanUtilsTest extends AndroidTestCase { // is specified. { final SuggestedWords predictedWords = new SuggestedWords( - new ArrayList<>(Arrays.asList(predicition1, predicition2, predicition3)), + new ArrayList<>(Arrays.asList(prediction1, prediction2, prediction3)), null /* rawSuggestions */, + null /* typedWord */, false /* typedWordValid */, false /* willAutoCorrect */, false /* isObsoleteSuggestions */, - SuggestedWords.INPUT_STYLE_PREDICTION); - final String PICKED_WORD = predicition2.mWord; + SuggestedWords.INPUT_STYLE_PREDICTION, + SuggestedWords.NOT_A_SEQUENCE_NUMBER); + final String PICKED_WORD = prediction2.mWord; assertNotSuggestionSpan( PICKED_WORD, SuggestionSpanUtils.getTextWithSuggestionSpan(getContext(), PICKED_WORD, @@ -137,17 +139,19 @@ public class SuggestionSpanUtilsTest extends AndroidTestCase { final ArrayList<SuggestedWordInfo> suggestedWordList = new ArrayList<>(); suggestedWordList.add(typed); - suggestedWordList.add(predicition1); - suggestedWordList.add(predicition2); - suggestedWordList.add(predicition3); + suggestedWordList.add(prediction1); + suggestedWordList.add(prediction2); + suggestedWordList.add(prediction3); suggestedWordList.addAll(Arrays.asList(corrections)); final SuggestedWords typedAndCollectedWords = new SuggestedWords( suggestedWordList, null /* rawSuggestions */, + null /* typedWord */, false /* typedWordValid */, false /* willAutoCorrect */, false /* isObsoleteSuggestions */, - SuggestedWords.INPUT_STYLE_TYPING); + SuggestedWords.INPUT_STYLE_TYPING, + SuggestedWords.NOT_A_SEQUENCE_NUMBER); for (final SuggestedWordInfo pickedWord : suggestedWordList) { final String PICKED_WORD = pickedWord.mWord; |