/** Validate that the report pages were generated correctly */
  private void validateReports(GraphContext context) {
    ReportService reportService = new ReportService(context);
    ReportModel mainApplicationReportModel = getMainApplicationReport(context);
    Path mainAppReport =
        reportService.getReportDirectory().resolve(mainApplicationReportModel.getReportFilename());

    ReportModel catchallApplicationReportModel = getMigrationIssuesReport(context);
    Path catchallAppReport =
        reportService
            .getReportDirectory()
            .resolve(catchallApplicationReportModel.getReportFilename());

    TestJavaApplicationOverviewUtil javaApplicationOverviewUtil =
        new TestJavaApplicationOverviewUtil();
    javaApplicationOverviewUtil.loadPage(mainAppReport);
    javaApplicationOverviewUtil.checkFilePathEffort("catchalltest", "FileWithoutCatchallHits", 13);
    javaApplicationOverviewUtil.checkFilePathEffort("catchalltest", "FileWithBoth", 27);
    javaApplicationOverviewUtil.checkFilePathEffort("catchalltest", "FileWithNoHintsRules", 63);

    TestMigrationIssuesReportUtil migrationIssuesReportUtil = new TestMigrationIssuesReportUtil();
    migrationIssuesReportUtil.loadPage(catchallAppReport);

    Assert.assertTrue(
        migrationIssuesReportUtil.checkIssue(
            "java.util.* found ", 7, 7, "Requires architectural decision or change", 49));
  }
  /** Validate that the report pages were generated correctly */
  private void validateReports(GraphContext context) {
    ReportService reportService = new ReportService(context);
    ReportModel reportModel =
        reportService.getUniqueByProperty(
            ReportModel.TEMPLATE_PATH,
            CreateJavaApplicationOverviewReportRuleProvider.TEMPLATE_APPLICATION_REPORT);
    Path appReportPath =
        Paths.get(reportService.getReportDirectory(), reportModel.getReportFilename());

    TestJavaApplicationOverviewUtil util = new TestJavaApplicationOverviewUtil();
    util.loadPage(appReportPath);
    util.checkFilePathAndTag(
        "Windup1x-javaee-example.war", "META-INF/maven/javaee/javaee/pom.properties", "Properties");
    util.checkFilePathEffort(
        "Windup1x-javaee-example.war", "META-INF/maven/javaee/javaee/pom.properties", 0);
    util.checkFilePathEffort(
        "Windup1x-javaee-example.war/WEB-INF/lib/joda-time-2.0.jar",
        "org.joda.time.tz.DateTimeZoneBuilder",
        32);
    validateStaticIPReport(context);
  }