### Question:
ResponseError extends Response { public static ResponseError from(Sc2Api.Response sc2ApiResponse) { if (!isSet(sc2ApiResponse) || sc2ApiResponse.getErrorCount() == 0) { throw new IllegalArgumentException("provided argument doesn't have error response"); } return new ResponseError(sc2ApiResponse.getErrorList(), sc2ApiResponse.getStatus(), sc2ApiResponse.getId()); } private  ResponseError(List<String> errors, Sc2Api.Status status, int id); static ResponseError from(Sc2Api.Response sc2ApiResponse); List<String> getErrors(); @Override boolean equals(Object o); @Override boolean canEqual(Object other); @Override int hashCode(); @Override String toString();  }### Answer:
@Test void throwsIllegalArgumentExceptionForNullArgumentsOrEmptyErrorListInSc2ApiResponse() { assertThatExceptionOfType(IllegalArgumentException.class) .isThrownBy(() -> ResponseError.from(nothing())) .withMessage("provided argument doesn't have error response"); assertThatExceptionOfType(IllegalArgumentException.class) .isThrownBy(() -> ResponseError.from(aSc2ApiResponse().build())) .withMessage("provided argument doesn't have error response"); }