### Question:
UriInfoImpl implements UriInfo { public URI getBaseUri() { URI u = URI.create(HttpUtils.getEndpointAddress(message)); return HttpUtils.toAbsoluteUri(u, message); } @SuppressWarnings("unchecked")  UriInfoImpl(Message m);  UriInfoImpl(Message m, MultivaluedMap<String, String> templateParams); URI getAbsolutePath(); UriBuilder getAbsolutePathBuilder(); URI getBaseUri(); UriBuilder getBaseUriBuilder(); String getPath(); String getPath(boolean decode); List<PathSegment> getPathSegments(); List<PathSegment> getPathSegments(boolean decode); MultivaluedMap<String, String> getQueryParameters(); MultivaluedMap<String, String> getQueryParameters(boolean decode); URI getRequestUri(); UriBuilder getRequestUriBuilder(); MultivaluedMap<String, String> getPathParameters(); MultivaluedMap<String, String> getPathParameters(boolean decode); List<Object> getMatchedResources(); List<String> getMatchedURIs(); List<String> getMatchedURIs(boolean decode); @Override URI relativize(URI uri); @Override URI resolve(URI uri);  }### Answer:
@Test public void testGetBaseUri() { UriInfoImpl u = new UriInfoImpl(mockMessage("http: assertEquals("Wrong base path", "http: u.getBaseUri().toString()); u = new UriInfoImpl(mockMessage("http: null); assertEquals("Wrong base path", "http: u.getBaseUri().toString()); }