INNER CODE UNIT · Python

find_reports

apache/ozone · dev-support/ci/junit_summary.py:157

def find_reports(base):
  found = set()
  for pattern in REPORT_PATTERNS:
    found.update(glob(os.path.join(base, pattern), recursive=True))
  # junit.sh keeps per-iteration copies under target/<check>/iterationN/ when ITERATIONS>1;
  # exclude them like _mvn_unit_report.sh does, so reruns are not counted multiple times.
  return sorted(path for path in found if "/iteration" not in path.replace(os.sep, "/"))


def main(argv=None):
  parser = argparse.ArgumentParser(description="Print a Markdown summary of JUnit XML test reports.")
  parser.add_argument("--path", default=".", help="directory to scan for TEST-*.xml reports")
  try:
    args = parser.parse_args(argv)
  except SystemExit:
    return 0
  # This script only decorates the step summary; it must NEVER fail the check, so exit 0 no matter what.
  try:

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…