@Test
    public void testGetRegisteredMimesWithParameters() throws Exception {
        //TIKA-1692

        // Media Type always keeps details / parameters
        String name = "application/xml; charset=UTF-8";
        MediaType mt = MediaType.parse(name);
        assertEquals(name, mt.toString());

        // Mime type loses details not in the file
        MimeType mimeType = this.mimeTypes.getRegisteredMimeType(name);
        assertEquals("application/xml", mimeType.toString());
        assertEquals(".xml", mimeType.getExtension());

        // But on well-known parameters stays
        name = "application/dita+xml; format=map";
        mt = MediaType.parse(name);
        assertEquals(name, mt.toString());
        mimeType = this.mimeTypes.getRegisteredMimeType(name);
        assertEquals(name, mimeType.toString());
        assertEquals(".ditamap", mimeType.getExtension());
    }
TIKA-2460 Test loading of custom-mimetypes.xml from sys prop.
tika-core/src/test/java/org/apache/tika/mime/MimeTypesReaderTest.java