Skip to content

Commit

Permalink
chore(engine): refactor test assertion to ignore milliseconds
Browse files Browse the repository at this point in the history
* The MySQL DueDate timestamp doesn't have millisecond accurracy, so current time comparisons fail.

Related to CAM-9924
  • Loading branch information
koevskinikola committed Mar 13, 2019
1 parent 6d0ca36 commit 2b706f8
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -635,6 +635,6 @@ public Void execute(CommandContext commandContext) {
TimerEntity secondTimerJob = (TimerEntity) managementService.createJobQuery().singleResult();
currentTime.add(Calendar.HOUR, 3);
assertEquals("R3/PT3H", secondTimerJob.getRepeat());
assertEquals(currentTime.getTime(), secondTimerJob.getDuedate());
assertEquals(sdf.format(currentTime.getTime()), sdf.format(secondTimerJob.getDuedate()));
}
}

0 comments on commit 2b706f8

Please sign in to comment.