@Test
public void testCanonicalUriWithNoAuthority() {

  URI uri;
  uri = NetUtils.getCanonicalUri(URI.create("scheme:/"), 2);
  assertEquals("scheme:/", uri.toString());
  uri = NetUtils.getCanonicalUri(URI.create("scheme:/path"), 2);
  assertEquals("scheme:/path", uri.toString());
  uri = NetUtils.getCanonicalUri(URI.create("scheme:///"), 2);
  assertEquals("scheme:///", uri.toString());
  uri = NetUtils.getCanonicalUri(URI.create("scheme:///path"), 2);
  assertEquals("scheme:///path", uri.toString());
}