@Test public void url_point_to_localhost() { URL url = (URL) this.urlBuilder.create(URL.class, null); assertEquals("localhost", url.getHost()); }
@Override public Object create(Object request, SpecimenContext context) { if (!request.equals(URL.class)) { return new NoSpecimen(); } try { return new URL("http: } catch (MalformedURLException e) { return new NoSpecimen(); } }
UrlBuilder implements SpecimenBuilder { @Override public Object create(Object request, SpecimenContext context) { if (!request.equals(URL.class)) { return new NoSpecimen(); } try { return new URL("http: } catch (MalformedURLException e) { return new NoSpecimen(); } } }
UrlBuilder implements SpecimenBuilder { @Override public Object create(Object request, SpecimenContext context) { if (!request.equals(URL.class)) { return new NoSpecimen(); } try { return new URL("http: } catch (MalformedURLException e) { return new NoSpecimen(); } }  }
UrlBuilder implements SpecimenBuilder { @Override public Object create(Object request, SpecimenContext context) { if (!request.equals(URL.class)) { return new NoSpecimen(); } try { return new URL("http: } catch (MalformedURLException e) { return new NoSpecimen(); } }  @Override Object create(Object request, SpecimenContext context); }
UrlBuilder implements SpecimenBuilder { @Override public Object create(Object request, SpecimenContext context) { if (!request.equals(URL.class)) { return new NoSpecimen(); } try { return new URL("http: } catch (MalformedURLException e) { return new NoSpecimen(); } }  @Override Object create(Object request, SpecimenContext context);  }