/**
   * Retrieves the Notes about the JUnit test.
   *
   * @param testCase JUnit test.
   * @return Notes about the JUnit test.
   */
  private String getJUnitNotes(CaseResult testCase, int buildNumber) {
    StringBuilder notes = new StringBuilder();
    notes.append(
        Messages.Results_JUnit_NotesForTestCase(
            testCase.getName(),
            testCase.getClassName(),
            testCase.getSkipCount(),
            testCase.getFailCount(),
            (testCase.getSuiteResult() != null ? testCase.getSuiteResult().getTimestamp() : null)));

    /* Added for appending build number and error message */
    notes.append("\nBuild no : " + buildNumber);
    if (null != testCase.getErrorDetails()) {
      notes.append("\nError Message : " + testCase.getErrorDetails());
    }

    return notes.toString();
  }
 /** Recount my children. */
 @Override
 public void tally() {
   passCount = failCount = skipCount = 0;
   duration = 0;
   for (CaseResult r : cases) {
     r.setClass(this);
     if (r.isSkipped()) {
       skipCount++;
     } else if (r.isPassed()) {
       passCount++;
     } else {
       failCount++;
     }
     // retrieve the class duration from these cases' suite time
     if (duration == 0) {
       duration = r.getSuiteResult().getDuration();
     }
   }
 }