VaadinServletService extends VaadinService { @Override public String resolveResource(String url) { Objects.requireNonNull(url, "Url cannot be null"); return contextResolver.resolveVaadinUri(url); } VaadinServletService(VaadinServlet servlet,
            DeploymentConfiguration deploymentConfiguration); protected  VaadinServletService(); VaadinServlet getServlet(); @Override String getMimeType(String resourceName); @Override void init(); static HttpServletRequest getCurrentServletRequest(); static VaadinServletResponse getCurrentResponse(); @Override String getServiceName(); @Override String getMainDivId(VaadinSession session, VaadinRequest request); @Override String resolveResource(String url); @Override URL getStaticResource(String path); @Override URL getResource(String path); @Override InputStream getResourceAsStream(String path); URL getResourceInServletContext(String path); @Override String getContextRootRelativePath(VaadinRequest request);  }
@Test public void resolveNullThrows() { try { service.resolveResource(null); Assert.fail("null should not resolve"); } catch (NullPointerException e) { Assert.assertEquals("Url cannot be null", e.getMessage()); } }
@Test public void resolveResource() { Assert.assertEquals("", service.resolveResource("")); Assert.assertEquals("foo", service.resolveResource("foo")); Assert.assertEquals("/foo", service.resolveResource("context: }
@Test public void resolveResourceNPM_production() { mocks.setProductionMode(true); Assert.assertEquals("", service.resolveResource("")); Assert.assertEquals("foo", service.resolveResource("foo")); Assert.assertEquals("/foo", service.resolveResource("context: }