Search in sources :

Example 1 with Comment

use of io.github.asw.i3a.operatorsWebClient.entitites.Comment in project InciDashboard_i3a by Arquisoft.

the class IncidentController method giveNewDataToIncident.

private void giveNewDataToIncident(InciInfo newInciData, Incident incident, String opId) {
    log.info("The old status of the incident is: " + incident.getStatus());
    log.info("The NEW status: " + newInciData.getStatus());
    incident.setStatus(newInciData.getStatus());
    log.info("There are " + incident.getComments().size() + " comments in the incident");
    log.info("Content of the new comment: " + newInciData.getComment());
    incident.getComments().add(new Comment(newInciData.getComment(), opId));
    log.info("UPDATE  " + incident.getComments().size() + " comments in the incident");
}
Also used : Comment(io.github.asw.i3a.operatorsWebClient.entitites.Comment)

Example 2 with Comment

use of io.github.asw.i3a.operatorsWebClient.entitites.Comment in project InciDashboard_i3a by Arquisoft.

the class CommentTest method extraTest.

@Test
public void extraTest() {
    Comment c = new Comment("hola", "idOp");
    Date d = new Date();
    assertTrue(c.getDate().getTime() <= d.getTime());
    Comment c2 = new Comment();
    assertTrue(c.canEquals(c2));
}
Also used : Comment(io.github.asw.i3a.operatorsWebClient.entitites.Comment) Date(java.util.Date) UnitTest(TestKit.UnitTest) Test(org.junit.Test)

Aggregations

Comment (io.github.asw.i3a.operatorsWebClient.entitites.Comment)2 UnitTest (TestKit.UnitTest)1 Date (java.util.Date)1 Test (org.junit.Test)1