URIHeaderDelegate implements RuntimeDelegate.HeaderDelegate<URI> { @Override public URI fromString(String header) { if (header == null) { throw new IllegalArgumentException(); } return URI.create(header); }  @Override URI fromString(String header); @Override String toString(URI uri);  }
@Test public void testValueOf() throws Exception { assertEquals(URI.create("http: }
@Test(expected = IllegalArgumentException.class) public void throwsExceptionWhenUriHeaderIsNull() throws Exception { uriHeaderDelegate.fromString(null); }