private void assertExpected(Detector detector, InputStream is, String expectedMime, String expectedDigest) throws IOException {
        MediaType mt = detector.detect(is, new Metadata());
        assertEquals(expectedMime, mt.toString());
        assertEquals(expectedDigest, digest(is));

    }
Test cases for detecting zip-based files.
tika-parsers/tika-parsers-standard/tika-parsers-standard-modules/tika-parser-zip-commons/src/test/java/org/apache/tika/detect/zip/ZipDetectionTest.java