open-build-service
open-build-service copied to clipboard
System notifications (proof of concept)
This PR is just a proposal for adding system notifications to OBS using the Notifications API and ActionCable.
To test the notifications open the rails console and try to broadcast for the logged-in user.
NotificationsChannel.broadcast_to(User.first, {title: 'Title', body: 'Body'})
Be sure to replace User.first with a logged-in user.
What about creating a rake task to send the test notification?
What about creating a rake task to send the test notification?
We don't need one atm. For now, we'll just go with rails c. Thanks for pointing that out, I've added the test instructions in the description.
Codecov Report
Merging #12213 (39196c0) into master (29fe2bf) will increase coverage by
3.13%. The diff coverage is100.00%.
:exclamation: Current head 39196c0 differs from pull request most recent head 52245d9. Consider uploading reports for the commit 52245d9 to get more accurate results
Additional details and impacted files
@@ Coverage Diff @@
## master #12213 +/- ##
==========================================
+ Coverage 88.21% 91.35% +3.13%
==========================================
Files 702 660 -42
Lines 24091 23090 -1001
==========================================
- Hits 21253 21093 -160
+ Misses 2838 1997 -841