@Test
@Ignore
public void testDeleteCommentOnMessage() throws Exception {
// get the message
SobaMessage sobaMessage = applicationManager.getMessageService().getMessage(getTestUser().getAccount(),
userMessage.getMessageId());
assertEquals(0, sobaMessage.getComments().size());
JSONObject json = new JSONObject();
json.put("comment", "Some Dumb Comment");
String url = getUrl() + "/" + userMessage.getMessageId() + "/comment";
makeRequest(url, "PUT", json, authToken);
sobaMessage = applicationManager.getMessageService().getMessage(getTestUser().getAccount(),
userMessage.getMessageId());
assertEquals(1, sobaMessage.getComments().size());
MessageComment messageComment = sobaMessage.getComments().get(0);
// now remove (nullify) the comment
makeRequest(url + "/" + messageComment.getCreated(), "DELETE", json, authToken);
sobaMessage = applicationManager.getMessageService().getMessage(getTestUser().getAccount(),
userMessage.getMessageId());
assertEquals(sobaMessage.getComments().get(0).getComment(), "comment removed by @" + testUser.getAlias());
}