NameBaseMimeResolver implements IPlatformMimeResolver { @Override public IMimeType resolveMimeTypeForFileName( String fileName ) { return extensionToMimeMap.get( extractExtension( fileName ) ); } NameBaseMimeResolver(); @Override String resolveMimeForFileName( String fileName ); @Override String resolveMimeForBundle( IPlatformImportBundle bundle ); @Override IMimeType resolveMimeTypeForFileName( String fileName ); @Override void addMimeType( IMimeType mimeType );  }
@Test public void testResolveMimeTypeForFileName() { MimeType expectedMimeType = new MimeType( "othertest/other-test-mime", "smt" ); IMimeType actualMimeType = resolver.resolveMimeTypeForFileName( "test.smt" ); assertEquals( actualMimeType, expectedMimeType ); }