aboutsummaryrefslogtreecommitdiffstats
path: root/tests/src/com/android/inputmethod/latin/DictionaryFacilitatorLruCacheTests.java
diff options
context:
space:
mode:
authorYohei Yukawa <yukawa@google.com>2018-07-06 10:10:54 -0700
committerYohei Yukawa <yukawa@google.com>2018-07-06 10:10:54 -0700
commitd3b93cc95061ada6a162d7989e313f818e6d4e15 (patch)
treea4e3eaee6b84d20817d82b2a263e0e47bcc98753 /tests/src/com/android/inputmethod/latin/DictionaryFacilitatorLruCacheTests.java
parenta497886dda70bbd401652560d11d8f4010985e96 (diff)
downloadlatinime-d3b93cc95061ada6a162d7989e313f818e6d4e15.tar.gz
latinime-d3b93cc95061ada6a162d7989e313f818e6d4e15.tar.xz
latinime-d3b93cc95061ada6a162d7989e313f818e6d4e15.zip
Migrate to Android Testing Support Lib (part 5/N)
This CL converts 19 test classes under com.android.inputmethod.latin to Android Testing Support Library. Bug: 110805255 Test: verified as follows. No new test failures. tapas adb LatinIME LatinIMETests arm64 userdebug && \ DISABLE_PROGUARD=true make -j LatinIME && \ adb install -r $OUT/system/app/LatinIME/LatinIME.apk && \ atest LatinIMETests:com.android.inputmethod.latin Change-Id: I878fcae0126f57c43a644af341e5a0a8ac8f5cc9
Diffstat (limited to 'tests/src/com/android/inputmethod/latin/DictionaryFacilitatorLruCacheTests.java')
-rw-r--r--tests/src/com/android/inputmethod/latin/DictionaryFacilitatorLruCacheTests.java18
1 files changed, 14 insertions, 4 deletions
diff --git a/tests/src/com/android/inputmethod/latin/DictionaryFacilitatorLruCacheTests.java b/tests/src/com/android/inputmethod/latin/DictionaryFacilitatorLruCacheTests.java
index 6b0bbc279..cdb5b8e72 100644
--- a/tests/src/com/android/inputmethod/latin/DictionaryFacilitatorLruCacheTests.java
+++ b/tests/src/com/android/inputmethod/latin/DictionaryFacilitatorLruCacheTests.java
@@ -16,16 +16,26 @@
package com.android.inputmethod.latin;
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertTrue;
+
import java.util.Locale;
-import android.test.AndroidTestCase;
-import android.test.suitebuilder.annotation.LargeTest;
+import android.support.test.InstrumentationRegistry;
+import android.support.test.filters.LargeTest;
+import android.support.test.runner.AndroidJUnit4;
+
+import org.junit.Test;
+import org.junit.runner.RunWith;
@LargeTest
-public class DictionaryFacilitatorLruCacheTests extends AndroidTestCase {
+@RunWith(AndroidJUnit4.class)
+public class DictionaryFacilitatorLruCacheTests {
+
+ @Test
public void testGetFacilitator() {
final DictionaryFacilitatorLruCache cache =
- new DictionaryFacilitatorLruCache(getContext(), "");
+ new DictionaryFacilitatorLruCache(InstrumentationRegistry.getTargetContext(), "");
final DictionaryFacilitator dictionaryFacilitatorEnUs = cache.get(Locale.US);
assertNotNull(dictionaryFacilitatorEnUs);