### Question:
HttpRequestBuilder { public HttpRequestBuilder withServerDate(Date date) { this.serverDate=DateUtil.copy(date); return this; } private  HttpRequestBuilder(); HttpRequestBuilder withMethod(HttpMethod method); HttpRequestBuilder withProtocolVersion(ProtocolVersion version); HttpRequestBuilder withHost(String host); HttpRequestBuilder withAbsolutePath(String absolutePath); HttpRequestBuilder withBody(String entity); HttpRequestBuilder withHeader(String name, String rawValue); HttpRequestBuilder withServerDate(Date date); HttpRequestBuilder withClientDate(Date date); HttpRequest build(); static HttpRequestBuilder newInstance();  }### Answer:
@Test public void testWithServerDate$nonNull() { Date date = new Date(System.currentTimeMillis()-3600000); HttpRequest build =sut().withServerDate(date).build(); assertThat(build.serverDate(),equalTo(date)); assertThat(build.clientDate(),nullValue()); verifyDefaultValues(build); }
@Test public void testWithServerDate$null() { Date before=new Date(); HttpRequest build=sut().withServerDate(null).build(); Date after=new Date(); assertDateIsInRange(before, after, build.serverDate()); assertThat(build.clientDate(),nullValue()); verifyDefaultValues(build); }