### Question:
ResponseStatus { @Override public String toString() { StringBuilder sb = new StringBuilder(64); print(sb); return sb.toString(); } ResponseStatus(ResponseType responseType);  ResponseStatus(ResponseType responseType, ErrorCode code, String message); ResponseStatus setCode(ErrorCode code); ResponseStatus setMessage(String m); ResponseType getResponseType(); ErrorCode getCodeOrDefaultDALERR(); ErrorCode getCodeOrDefault(ErrorCode defaultCode); String getMessage(); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); void print(StringBuilder stringBuilder);  }### Answer:
@Test public void testToString() throws Exception { ResponseStatus responseStatus = new ResponseStatus(ResponseStatus.ResponseType.ABORT) .setCode(ErrorCode.ABORT_SERVER_UNSYNC).setMessage("cdba"); ResponseStatus responseStatus1 = new ResponseStatus(ResponseStatus.ResponseType.ABORT) .setCode(ErrorCode.ABORT_SERVER_UNSYNC).setMessage("abcd"); System.out.println(responseStatus); System.out.println(responseStatus1); Assert.assertFalse(responseStatus.equals(responseStatus1)); ResponseStatus responseStatus2 = new ResponseStatus(ResponseStatus.ResponseType.OK) .setCode(ErrorCode.ABORT_SERVER_UNSYNC).setMessage("cdba"); ResponseStatus responseStatus3 = new ResponseStatus(ResponseStatus.ResponseType.OK) .setCode(ErrorCode.ABORT_SERVER_UNSYNC).setMessage("cdba"); System.out.println(responseStatus2); System.out.println(responseStatus3); Assert.assertEquals(responseStatus2, responseStatus3); ResponseStatus responseStatus4 = new ResponseStatus(ResponseStatus.ResponseType.OK) .setCode(ErrorCode.ABORT_SERVER_UNSYNC).setMessage("cdba"); ResponseStatus responseStatus5 = new ResponseStatus(ResponseStatus.ResponseType.DALERR) .setCode(ErrorCode.ABORT_SERVER_UNSYNC).setMessage("cdba"); System.out.println(responseStatus4); System.out.println(responseStatus5); Assert.assertFalse(responseStatus4.equals(responseStatus5)); }