@Test
public void testToEvent() {
// System.out.println("ToEvent");
IntervalInt event = new Event();
event.setInterval(0, 1);
DateTime start = settings.toDateTime(event.getStart());
DateTime end = settings.toDateTime(event.getEnd());
assertEqualsEvent(event, settings.toInterval(start, end));
event.setInterval(settings.getTimeslotsPerDay(), 1);
start = settings.toDateTime(event.getStart());
end = settings.toDateTime(event.getEnd());
assertEqualsEvent(event, settings.toInterval(start, end));
event.setInterval(0, 2);
event.setInterval(settings.getTimeslotsPerDay(), 1);
start = settings.toDateTime(event.getStart());
end = settings.toDateTime(event.getEnd());
assertEqualsEvent(event, settings.toInterval(start, end));
event.setInterval(settings.getTimeslotsPerDay() - 1, 1);
event.setInterval(settings.getTimeslotsPerDay(), 1);
start = settings.toDateTime(event.getStart());
end = settings.toDateTime(event.getEnd());
assertEqualsEvent(event, settings.toInterval(start, end));
}