### Question:
SuperBatchPluginResource implements DownloadableResource, BatchResource, PluginResource { protected static String getType(String path) { int index = path.lastIndexOf('.'); if (index > -1 && index < path.length()) return path.substring(index + 1); return ""; } SuperBatchPluginResource(String type, Map<String, String> params); protected  SuperBatchPluginResource(String resourceName, String type, Map<String, String> params); static boolean matches(String path); static SuperBatchPluginResource createBatchFor(PluginResource pluginResource); static SuperBatchPluginResource parse(String path, Map<String, String> params); boolean isResourceModified(HttpServletRequest request, HttpServletResponse response); void serveResource(HttpServletRequest request, HttpServletResponse response); void streamResource(OutputStream out); String getContentType(); void add(DownloadableResource downloadableResource); boolean isEmpty(); String getUrl(); Map<String, String> getParams(); String getVersion(WebResourceIntegration integration); String getType(); boolean isCacheSupported(); String getResourceName(); String getModuleCompleteKey(); @Override String toString();  }### Answer:
@Test public void testGetType() { assertEquals("css", SuperBatchPluginResource.getType("/foo.css")); assertEquals("js", SuperBatchPluginResource.getType("/superbatch/js/foo.js")); assertEquals("", SuperBatchPluginResource.getType("/superbatch/js/foo.")); assertEquals("", SuperBatchPluginResource.getType("/superbatch/js/foo")); }