openshift-pipelines / pipelines-as-code

Pipelines-as-Code for Tekton
https://pipelinesascode.com
Apache License 2.0
130 stars 80 forks source link

Fix matching proper PipelineRun with /test #1652

Closed chmouel closed 5 months ago

chmouel commented 6 months ago

We were always getting the first one of the pipelinerun, i thought the filtering was already done and it would always be only one PipelineRun but we re-fetch everything on resolve.Resolve, so redoing the filtering properly.

Improve e2e to make sure it handles this properly to explicit test the proper PipelineRun.

Refactor a bit the gitea tests for GitOPS commands to be in its own file. g# Changes

Submitter Checklist

codecov[bot] commented 5 months ago

Codecov Report

Attention: Patch coverage is 61.53846% with 5 lines in your changes are missing coverage. Please review.

Project coverage is 64.13%. Comparing base (28178ab) to head (cf35b5f). Report is 1 commits behind head on main.

Files Patch % Lines
pkg/pipelineascode/match.go 58.33% 4 Missing and 1 partial :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1652 +/- ## ========================================== + Coverage 64.12% 64.13% +0.01% ========================================== Files 141 141 Lines 10878 10878 ========================================== + Hits 6975 6977 +2 + Misses 3387 3385 -2 Partials 516 516 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

piyush-garg commented 5 months ago

/lgtm

savitaashture commented 5 months ago

/lgtm