Skip to content

Running tests with Airbrake

shime edited this page Oct 27, 2012 · 2 revisions

When you run your tests, you might notice that the Airbrake service is recording notices generated using #notify when you don't expect it to. You can use code like this in your test_helper.rb or spec_helper.rb files to redefine that method so those errors are not reported while running tests.

module Airbrake
  def self.notify(exception, opts = {})
    # do nothing.
  end
end