Skip to content

Commit

Permalink
[JENKINS-10529] Fixed visualization when a date range is provided (br…
Browse files Browse the repository at this point in the history
…oken by previous commit).
  • Loading branch information
mambu committed Jul 30, 2011
1 parent 7de5883 commit 04adf38
Showing 1 changed file with 6 additions and 4 deletions.
Expand Up @@ -91,16 +91,18 @@ public Graph getSummaryGraph() {
Run nextRun = run.getNextBuild();

if (nextRun != null) {
if (!runDay.isBefore(firstDay)) { // skip run before firstDay
LocalDate nextRunDay = new LocalDate(nextRun.getTimestamp());
// skip run before firstDay, but keep if next build is after start date
if (!runDay.isBefore(firstDay)
|| runDay.isBefore(firstDay) && !nextRunDay.isBefore(firstDay)) {
// if next run is not the same day, use this test to summarize
LocalDate nextRunDay = new LocalDate(nextRun.getTimestamp());
if (nextRunDay.isAfter(runDay)) {
summarize(summaries, run, runDay, nextRunDay.minusDays(1));
summarize(summaries, run, (runDay.isBefore(firstDay) ? firstDay : runDay), nextRunDay.minusDays(1));
}
}
} else {
// use this run's test result from last run to today
summarize(summaries, run, runDay, today);
summarize(summaries, run, (runDay.isBefore(firstDay) ? firstDay : runDay), today);
}

run = nextRun;
Expand Down

0 comments on commit 04adf38

Please sign in to comment.