use of com.google.gerrit.testutil.InMemoryRepositoryManager.Repo in project gerrit by GerritCodeReview.
the class AbstractQueryChangesTest method byAfter.
@Test
public void byAfter() throws Exception {
long thirtyHoursInMs = MILLISECONDS.convert(30, HOURS);
resetTimeWithClockStep(thirtyHoursInMs, MILLISECONDS);
TestRepository<Repo> repo = createProject("repo");
long startMs = TestTimeUtil.START.getMillis();
Change change1 = insert(repo, newChange(repo), null, new Timestamp(startMs));
Change change2 = insert(repo, newChange(repo), null, new Timestamp(startMs + thirtyHoursInMs));
TestTimeUtil.setClockStep(0, MILLISECONDS);
assertQuery("after:2009-10-03");
assertQuery("after:\"2009-10-01 20:59:59 -0400\"", change2);
assertQuery("after:\"2009-10-01 20:59:59 -0000\"", change2);
assertQuery("after:2009-10-01", change2);
assertQuery("after:2009-09-30", change2, change1);
}
Aggregations