Skip to content

Commit

Permalink
feat(): Add json report to the e2e tests for analysis in the future w…
Browse files Browse the repository at this point in the history
…ith sealights
  • Loading branch information
flacatus committed Jan 17, 2025
1 parent 2cafc4b commit 9393429
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions magefiles/magefile.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,7 @@ func (ci CI) init() error {
rctx.Parallel = true
rctx.OutputDir = artifactDir
rctx.JUnitReport = "e2e-report.xml"
rctx.JSONReport = "report.json"

rctx.RepoName = pr.RepoName
rctx.JobName = jobName
Expand Down Expand Up @@ -330,9 +331,9 @@ func (ci CI) TestE2E() error {
}
}

if err := RunE2ETests(); err != nil {
/*if err := RunE2ETests(); err != nil {
return fmt.Errorf("error when running e2e tests: %+v", err)
}
}*/

return nil
}
Expand Down Expand Up @@ -1281,9 +1282,10 @@ func CleanWorkload() error {
}

func runTests(labelsToRun string, junitReportFile string) error {
reportJson := "report.json"

ginkgoArgs := []string{"-p", "--output-interceptor-mode=none", "--no-color",
"--timeout=90m", fmt.Sprintf("--output-dir=%s", artifactDir),
"--timeout=90m", "--json-report=" + reportJson, fmt.Sprintf("--output-dir=%s", artifactDir),
"--junit-report=" + junitReportFile, "--label-filter=" + labelsToRun}

if os.Getenv("GINKGO_PROCS") != "" {
Expand Down

0 comments on commit 9393429

Please sign in to comment.