diff options
author | 2014-02-04 05:53:08 -0800 | |
---|---|---|
committer | 2014-02-04 05:53:08 -0800 | |
commit | 1222a6116617f4d7bbbcb95602932e3250018c8c (patch) | |
tree | 83a3e370b5d7f7008454541906392a3d512e1e4d /tests/src/com/android/inputmethod/latin/BinaryDictionaryDecayingTests.java | |
parent | f34a3e23d04a697313b6b136b5133ef5f2ad92c7 (diff) | |
parent | aaf864db7b978461f16acfce972c38dea207afd9 (diff) | |
download | latinime-1222a6116617f4d7bbbcb95602932e3250018c8c.tar.gz latinime-1222a6116617f4d7bbbcb95602932e3250018c8c.tar.xz latinime-1222a6116617f4d7bbbcb95602932e3250018c8c.zip |
am aaf864db: Merge "Separate header class from FormatSpec."
* commit 'aaf864db7b978461f16acfce972c38dea207afd9':
Separate header class from FormatSpec.
Diffstat (limited to 'tests/src/com/android/inputmethod/latin/BinaryDictionaryDecayingTests.java')
-rw-r--r-- | tests/src/com/android/inputmethod/latin/BinaryDictionaryDecayingTests.java | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/tests/src/com/android/inputmethod/latin/BinaryDictionaryDecayingTests.java b/tests/src/com/android/inputmethod/latin/BinaryDictionaryDecayingTests.java index 343ab420c..c41bbd768 100644 --- a/tests/src/com/android/inputmethod/latin/BinaryDictionaryDecayingTests.java +++ b/tests/src/com/android/inputmethod/latin/BinaryDictionaryDecayingTests.java @@ -22,6 +22,7 @@ import android.util.Pair; import com.android.inputmethod.latin.makedict.CodePointUtils; import com.android.inputmethod.latin.makedict.DictDecoder; +import com.android.inputmethod.latin.makedict.DictionaryHeader; import com.android.inputmethod.latin.makedict.FormatSpec; import com.android.inputmethod.latin.makedict.FusionDictionary; import com.android.inputmethod.latin.makedict.FusionDictionary.PtNode; @@ -102,14 +103,14 @@ public class BinaryDictionaryDecayingTests extends AndroidTestCase { getContext().getCacheDir()); FileUtils.deleteRecursively(file); Map<String, String> attributeMap = new HashMap<String, String>(); - attributeMap.put(FormatSpec.FileHeader.DICTIONARY_ID_KEY, dictId); - attributeMap.put(FormatSpec.FileHeader.DICTIONARY_LOCALE_KEY, dictId); - attributeMap.put(FormatSpec.FileHeader.DICTIONARY_VERSION_KEY, + attributeMap.put(DictionaryHeader.DICTIONARY_ID_KEY, dictId); + attributeMap.put(DictionaryHeader.DICTIONARY_LOCALE_KEY, dictId); + attributeMap.put(DictionaryHeader.DICTIONARY_VERSION_KEY, String.valueOf(TimeUnit.MILLISECONDS.toSeconds(System.currentTimeMillis()))); - attributeMap.put(FormatSpec.FileHeader.USES_FORGETTING_CURVE_KEY, - FormatSpec.FileHeader.ATTRIBUTE_VALUE_TRUE); - attributeMap.put(FormatSpec.FileHeader.HAS_HISTORICAL_INFO_KEY, - FormatSpec.FileHeader.ATTRIBUTE_VALUE_TRUE); + attributeMap.put(DictionaryHeader.USES_FORGETTING_CURVE_KEY, + DictionaryHeader.ATTRIBUTE_VALUE_TRUE); + attributeMap.put(DictionaryHeader.HAS_HISTORICAL_INFO_KEY, + DictionaryHeader.ATTRIBUTE_VALUE_TRUE); if (BinaryDictionary.createEmptyDictFile(file.getAbsolutePath(), FormatSpec.VERSION4, attributeMap)) { return file; |