if Supermarket::Config.sentry_url.present? && !Rails.env.test?
  require 'raven'

  Raven.configure do |config|
    config.dsn = Supermarket::Config.sentry_url
  end
end

if Supermarket::Config.sentry_url.present? && !Rails.env.test?
  require 'raven'
  require 'raven/sidekiq'

  Raven.configure do |config|
    config.dsn = Supermarket::Config.sentry_url
  end
end

Send Sidekiq errors to Sentry
Send Sidekiq errors to Sentry
