You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tika.apache.org by ta...@apache.org on 2019/11/19 16:18:46 UTC
[tika] 04/06: HEIF detection unit test. When tooling improves,
should ideally create another HEIF test file with another codec too
This is an automated email from the ASF dual-hosted git repository.
tallison pushed a commit to branch branch_1x
in repository https://gitbox.apache.org/repos/asf/tika.git
commit dc7bf6c09455abd9e44ccf2dbae97c032712d967
Author: Nick Burch <ni...@gagravarr.org>
AuthorDate: Mon Nov 18 14:57:09 2019 +0000
HEIF detection unit test. When tooling improves, should ideally create another HEIF test file with another codec too
---
.../src/test/java/org/apache/tika/mime/TestMimeTypes.java | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/tika-parsers/src/test/java/org/apache/tika/mime/TestMimeTypes.java b/tika-parsers/src/test/java/org/apache/tika/mime/TestMimeTypes.java
index 131dd23..b4eb338 100644
--- a/tika-parsers/src/test/java/org/apache/tika/mime/TestMimeTypes.java
+++ b/tika-parsers/src/test/java/org/apache/tika/mime/TestMimeTypes.java
@@ -407,6 +407,18 @@ public class TestMimeTypes {
}
@Test
+ public void testHeifDetection() throws Exception {
+ // HEIF image using the HEVC Codec == HEIC
+ // created using https://compare.rokka.io/_compare on testJPEG_GEO.jpg
+ assertType("image/heic", "testHEIF.heic");
+ assertTypeByData("image/heic", "testHEIF.heic");
+ assertTypeByName("image/heic", "testHEIF.heic");
+
+ // TODO Create a HEIF using another codec, to test .heif data
+ assertTypeByName("image/heif", "testHEIF.heif");
+ }
+
+ @Test
public void testJpegDetection() throws Exception {
assertType("image/jpeg", "testJPEG.jpg");
assertTypeByData("image/jpeg", "testJPEG.jpg");