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: add slack notification on failed integration tests #381

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

hanshal101
Copy link

Fixes #332
Closes #332

Description

This PR adds the feature to give alerts on slack when the integration tests fails.

TODO

@anfredette , we need to add a Github secret named SLACK_WEBHOOK_URL to enable the alerts.

Copy link

codecov bot commented Feb 24, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Please upload report for BASE (main@adda074). Learn more about missing BASE report.
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #381   +/-   ##
=======================================
  Coverage        ?   28.13%           
=======================================
  Files           ?      128           
  Lines           ?    11209           
  Branches        ?        0           
=======================================
  Hits            ?     3154           
  Misses          ?     7773           
  Partials        ?      282           
Flag Coverage Δ
unittests 28.13% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

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

Copy link
Contributor

@dave-tucker dave-tucker left a comment

Choose a reason for hiding this comment

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

Thanks for the contribution. I left some comments, but reading up on this some more it seems like webhooks are being deprecated no longer recommended for this usecase + we don't have the ability to add them easily on the K8s slack instance.

We can certainly request a webhook from the admins, but it might make more sense to do use the Github integration like this: https://github.com/integrations/slack?tab=readme-ov-file#workflow-notification-filters

That's more flexible since we can subscribe/unsubscribe to notifications in the channel whenever we like.

@hanshal101
Copy link
Author

Thanks @dave-tucker for the review, I have updated the CI to the official slackapi, I have added a simple string for the message, let me know if we need more detailed one or not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Notify Kubernetes #bpfman channel if nightly bpfman-operator integration test fails
2 participants