@Test public void shouldGiveFullUrlWithPortWhenPortIsNot80() { when(request.getScheme()).thenReturn("http"); when(request.getServerName()).thenReturn("caelum.com.br"); when(request.getServerPort()).thenReturn(8080); when(request.getContextPath()).thenReturn("/context/"); assertEquals("http: }
public String getApplicationPath() { return request.getScheme() + ": + (request.getServerPort() != 80? ":" + request.getServerPort() : "") + request.getContextPath(); }
ApplicationConfiguration implements Configuration { public String getApplicationPath() { return request.getScheme() + ": + (request.getServerPort() != 80? ":" + request.getServerPort() : "") + request.getContextPath(); } }
ApplicationConfiguration implements Configuration { public String getApplicationPath() { return request.getScheme() + ": + (request.getServerPort() != 80? ":" + request.getServerPort() : "") + request.getContextPath(); } ApplicationConfiguration(HttpServletRequest request); }
ApplicationConfiguration implements Configuration { public String getApplicationPath() { return request.getScheme() + ": + (request.getServerPort() != 80? ":" + request.getServerPort() : "") + request.getContextPath(); } ApplicationConfiguration(HttpServletRequest request); String getApplicationPath(); }
ApplicationConfiguration implements Configuration { public String getApplicationPath() { return request.getScheme() + ": + (request.getServerPort() != 80? ":" + request.getServerPort() : "") + request.getContextPath(); } ApplicationConfiguration(HttpServletRequest request); String getApplicationPath();  }