query.setDuration(Format.TIME, DURATION);
assertEquals("Incorrect duration returned", DURATION, query.getDuration());
}
@Test
public void durationQueryToString() {
DurationQuery query = new DurationQuery(Format.TIME);
query.setDuration(Format.TIME, 1234);
String s = query.toString();
assertTrue("toString() did not return format", s.contains("format=TIME"));
assertTrue("toString() did not return duration", s.contains("duration=1234"));
}