@Test public void testSetMessage() throws Exception { String testMessage = "Message for Unit Test"; String newMessage = "New Unit Test Message"; QueryStatus.QueryStatusEnum testStatus = QueryStatus.QueryStatusEnum.WARNING; QueryStatus one = new QueryStatus(testStatus, testMessage); Assert.assertEquals("getMessage should return message passed to constructor.", testMessage, one.getMessage()); one.setMessage(newMessage); Assert.assertEquals("getMessage should return status set with setStatus.", newMessage, one.getMessage()); }
public void setMessage(String message) { this.message = message; }
QueryStatus { public void setMessage(String message) { this.message = message; } }
QueryStatus { public void setMessage(String message) { this.message = message; } QueryStatus();  QueryStatus(QueryStatusEnum status, String message); }
QueryStatus { public void setMessage(String message) { this.message = message; } QueryStatus();  QueryStatus(QueryStatusEnum status, String message); @Override boolean equals(Object o); @Override int hashCode(); QueryStatusEnum getStatus(); void setStatus(QueryStatusEnum status); String getMessage(); void setMessage(String message); }
QueryStatus { public void setMessage(String message) { this.message = message; } QueryStatus();  QueryStatus(QueryStatusEnum status, String message); @Override boolean equals(Object o); @Override int hashCode(); QueryStatusEnum getStatus(); void setStatus(QueryStatusEnum status); String getMessage(); void setMessage(String message);  }