@Test public void buildShouldReturnDefaultErrorWhenNoParameter() { ErrorResponse expected = new ErrorResponse(ErrorResponse.DEFAULT_ERROR_MESSAGE, Optional.empty()); ErrorResponse actual = ErrorResponse .builder() .build(); assertThat(actual).isEqualToComparingFieldByField(expected); }
public static Builder builder() { return new Builder(); }
ErrorResponse implements Method.Response { public static Builder builder() { return new Builder(); } }
ErrorResponse implements Method.Response { public static Builder builder() { return new Builder(); } @VisibleForTesting  ErrorResponse(String type, Optional<String> description); }
ErrorResponse implements Method.Response { public static Builder builder() { return new Builder(); } @VisibleForTesting  ErrorResponse(String type, Optional<String> description); static Builder builder(); String getType(); Optional<String> getDescription(); @Override boolean equals(Object o); @Override int hashCode(); }
ErrorResponse implements Method.Response { public static Builder builder() { return new Builder(); } @VisibleForTesting  ErrorResponse(String type, Optional<String> description); static Builder builder(); String getType(); Optional<String> getDescription(); @Override boolean equals(Object o); @Override int hashCode(); static final Method.Response.Name ERROR_METHOD; }