class CheckerJobs::Notifiers::BugsnagDefaultFormatter
Public Class Methods
new(check, count, entries)
click to toggle source
# File lib/checker_jobs/notifiers/bugsnag_default_formatter.rb, line 4 def initialize(check, count, entries) @check = check @count = count @entries = entries end
Public Instance Methods
base_error()
click to toggle source
# File lib/checker_jobs/notifiers/bugsnag_default_formatter.rb, line 10 def base_error CheckerJobs::Notifiers::Bugsnag::Error.new(error_message) end
context()
click to toggle source
# File lib/checker_jobs/notifiers/bugsnag_default_formatter.rb, line 18 def context "checker_jobs" end
grouping_hash()
click to toggle source
# File lib/checker_jobs/notifiers/bugsnag_default_formatter.rb, line 22 def grouping_hash error_message end
severity()
click to toggle source
# File lib/checker_jobs/notifiers/bugsnag_default_formatter.rb, line 14 def severity "warning" end
tab_infos()
click to toggle source
# File lib/checker_jobs/notifiers/bugsnag_default_formatter.rb, line 26 def tab_infos ["triggered_check", triggered_check] end
Private Instance Methods
error_message()
click to toggle source
# File lib/checker_jobs/notifiers/bugsnag_default_formatter.rb, line 42 def error_message "(#{@check.klass}) #{human_check_name} was triggered!" end
triggered_check()
click to toggle source
# File lib/checker_jobs/notifiers/bugsnag_default_formatter.rb, line 32 def triggered_check { klass: @check.klass, name: @check.name, count: @count, entries: @entries&.map { |entry| format_entry(entry) }, source_code_url: repository_url, } end