Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(STONEINTG-999): report test status for group snapshot #860

Merged
merged 2 commits into from
Sep 25, 2024

Conversation

hongweiliu17
Copy link
Contributor

@hongweiliu17 hongweiliu17 commented Sep 5, 2024

  • update template to generate text reported to git provider
  • report test status for group snapshot

Signed-off-by: Hongwei Liu hongliu@redhat.com

Maintainers will complete the following section

status/status.go Fixed Show fixed Hide fixed
@hongweiliu17 hongweiliu17 force-pushed the STONEINTG-999-1 branch 3 times, most recently from e3bf184 to 1f23888 Compare September 5, 2024 05:05
@codecov-commenter
Copy link

codecov-commenter commented Sep 5, 2024

Codecov Report

Attention: Patch coverage is 60.56338% with 56 lines in your changes missing coverage. Please review.

Please upload report for BASE (main@1fa734b). Learn more about missing BASE report.

Files with missing lines Patch % Lines
...al/controller/statusreport/statusreport_adapter.go 56.32% 26 Missing and 12 partials ⚠️
status/status.go 74.35% 7 Missing and 3 partials ⚠️
gitops/snapshot.go 42.85% 4 Missing and 4 partials ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #860   +/-   ##
=======================================
  Coverage        ?   69.24%           
=======================================
  Files           ?       43           
  Lines           ?     4552           
  Branches        ?        0           
=======================================
  Hits            ?     3152           
  Misses          ?     1062           
  Partials        ?      338           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@hongweiliu17
Copy link
Contributor Author

hongweiliu17 commented Sep 5, 2024

The new text template with component snapshot info for group snapshot can generate content like below:

  • Pipelinerun: pipelinerun-component-sample

  • Task Duration Test Suite Status Details
    example-task-1 5m30s example-namespace-1 ✔️ SUCCESS ✔️ 2 success(es)
    ⚠️ 1 warning(s)
    example-task-2 2m0s ✔️ Reason: Succeeded ✔️ Reason: Succeeded
    example-task-31 1s example-namespace-3 ❌ FAILURE ❌ 1 failure(s)
    example-task-42 1s example-namespace-4 ⚠️ WARNING ⚠️ 1 warning(s)
    example-task-5 5m0s example-namespace-5 ✅ SKIPPED
    example-task-6 1s example-namespace-6 ❗ ERROR

    The group snapshot is generated for the component snasphots as below:

    Component Snapshot BuildPipelineRun
    com1 snapshot1 buildPLR1
    com2 snapshot2 buildPLR2
    com3 snapshot3 buildPLR3

    Footnotes

    1. example note 3

    2. example note 4

    @hongweiliu17 hongweiliu17 marked this pull request as draft September 5, 2024 12:04
    @hongweiliu17 hongweiliu17 changed the title feat(STONEINTG-999): update template in status report feat(STONEINTG-999): report test status for group snapshot Sep 10, 2024
    @hongweiliu17
    Copy link
    Contributor Author

    hongweiliu17 commented Sep 10, 2024

    The feature code is ready for review. I will work on the unit test part next.

    status/status.go Outdated Show resolved Hide resolved
    * update status report template to generate text including group
      snapshot info
    
    Signed-off-by: Hongwei Liu <hongliu@redhat.com>
    Copy link
    Collaborator

    @dirgim dirgim left a comment

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    LGTM

    Copy link
    Contributor

    @chipspeak chipspeak left a comment

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    LGTM Inspirational stuff as always Hongwei!

    @hongweiliu17
    Copy link
    Contributor Author

    * Update EnsureSnapshotTestStatusReportedToGitProvider to support
      group snapshot
    
    Signed-off-by: Hongwei Liu <hongliu@redhat.com>
    Copy link

    openshift-ci bot commented Sep 24, 2024

    New changes are detected. LGTM label has been removed.

    @hongweiliu17
    Copy link
    Contributor Author

    Found one bug in when SetLastUpdateTime, because this is a loop, so we may need to also include the componentName in https://github.com/konflux-ci/integration-service/blob/main/status/status.go#L48. To make the review easier, I prefer to merge this PR then commit another PR to fix it.

    @hongweiliu17
    Copy link
    Contributor Author

    /retest

    1 similar comment
    @hongweiliu17
    Copy link
    Contributor Author

    /retest

    @hongweiliu17
    Copy link
    Contributor Author

    /retest-required

    @hongweiliu17
    Copy link
    Contributor Author

    /retest

    4 similar comments
    @dirgim
    Copy link
    Collaborator

    dirgim commented Sep 24, 2024

    /retest

    @flacatus
    Copy link
    Contributor

    /retest

    @flacatus
    Copy link
    Contributor

    /retest

    @flacatus
    Copy link
    Contributor

    /retest

    @hongweiliu17 hongweiliu17 merged commit 691989d into konflux-ci:main Sep 25, 2024
    12 checks passed
    @hongweiliu17 hongweiliu17 deleted the STONEINTG-999-1 branch September 25, 2024 05:22
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Projects
    None yet
    Development

    Successfully merging this pull request may close these issues.

    8 participants