diff options
author | 2013-08-21 15:27:36 +0900 | |
---|---|---|
committer | 2013-08-21 20:02:18 +0900 | |
commit | 558e34c7bd8b146695ce1dbda6ed9933ddd19300 (patch) | |
tree | 51f4d16d69447ce5cb1df4ec36b7479a18ef42d3 /tests/src | |
parent | f739807a3f4dc02ebbd219a2f88f03a593b39a7a (diff) | |
download | latinime-558e34c7bd8b146695ce1dbda6ed9933ddd19300.tar.gz latinime-558e34c7bd8b146695ce1dbda6ed9933ddd19300.tar.xz latinime-558e34c7bd8b146695ce1dbda6ed9933ddd19300.zip |
Make readPtNode be called with the address from the beginning of the file.
Change-Id: I8939fdfb4f79e55bcd7393633784effb30df3f8f
Diffstat (limited to 'tests/src')
-rw-r--r-- | tests/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderEncoderTests.java | 4 | ||||
-rw-r--r-- | tests/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtilsTests.java | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/tests/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderEncoderTests.java b/tests/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderEncoderTests.java index d50d1ac96..f30be97f3 100644 --- a/tests/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderEncoderTests.java +++ b/tests/src/com/android/inputmethod/latin/makedict/BinaryDictDecoderEncoderTests.java @@ -512,8 +512,8 @@ public class BinaryDictDecoderEncoderTests extends AndroidTestCase { return null; } if (fileHeader == null) return null; - return BinaryDictDecoderUtils.getWordAtAddress(dictDecoder, fileHeader.mHeaderSize, - address - fileHeader.mHeaderSize, fileHeader.mFormatOptions).mWord; + return BinaryDictDecoderUtils.getWordAtPosition(dictDecoder, fileHeader.mHeaderSize, + address, fileHeader.mFormatOptions).mWord; } private long runGetTerminalPosition(final Ver3DictDecoder dictDecoder, final String word, diff --git a/tests/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtilsTests.java b/tests/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtilsTests.java index 878417084..68976a7ca 100644 --- a/tests/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtilsTests.java +++ b/tests/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtilsTests.java @@ -228,8 +228,8 @@ public class BinaryDictIOUtilsTests extends AndroidTestCase { new Ver3DictDecoder.DictionaryBufferFromReadOnlyByteBufferFactory()); final FileHeader fileHeader = dictDecoder.readHeader(); assertEquals(word, - BinaryDictDecoderUtils.getWordAtAddress(dictDecoder, fileHeader.mHeaderSize, - position - fileHeader.mHeaderSize, fileHeader.mFormatOptions).mWord); + BinaryDictDecoderUtils.getWordAtPosition(dictDecoder, fileHeader.mHeaderSize, + position, fileHeader.mFormatOptions).mWord); } catch (IOException e) { Log.e(TAG, "Raised an IOException while looking up a word", e); } catch (UnsupportedFormatException e) { |