You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* The `TestGithubSecondPullRequestConcurrencyMultiplePR` test occasionally
failed due to timing issues related to PipelineRun cleanup.
* The check for the final number of PipelineRuns sometimes occurred before the
cancellation/cleanup mechanism had fully processed superseded runs.
* Introduced a wait loop to allow sufficient time for PipelineRuns to be
garbage collected or cleaned up by the controller.
* This ensures the assertion for the exact number of expected PipelineRuns is
more reliable, reducing test flakiness.
Signed-off-by: Chmouel Boudjnah <chmouel@redhat.com>
t.Fatalf("number of cleaned PR is %d we expected to have %d after the cleanup: PipelineRun and its statuses: %+v", len(matchingPRs), allPipelinesRunAfterCleanUp, allPipelineRunsNamesAndStatus)
160
-
return
160
+
runcnx.Clients.Log.Infof("we are still waiting for pipelineruns to be cleaned up, we have %d/%d, sleeping 10s, %d/%d", len(matchingPRs), allPipelinesRunsCnt, i, maxWaitLoopRun)
161
+
time.Sleep(10*time.Second)
161
162
}
163
+
assert.Assert(t, success, "we didn't get %d pipelineruns as successful, some of them are still pending or it's abnormally slow to process the Q: %s", allPipelinesRunsCnt, allPipelineRunsNamesAndStatus)
0 commit comments