File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -12,15 +12,17 @@ not_jruby = %i[ruby mingw x64_mingw].freeze
1212
1313gem 'activesupport' , '>= 4.2'
1414gem 'byebug' , platforms : not_jruby
15- # Open source licensed elasticsearch
16- gem 'honeybadger' , '>= 2.0'
1715gem 'irb' , '~> 1.0'
1816# Minimum of 0.5.0 for specific error classes
1917gem 'mysql2' , '>= 0.5.0' , platforms : not_jruby
2018gem 'redcarpet' , '~> 3.5' , platforms : not_jruby
2119gem 'rspec_junit_formatter' , '~> 0.4'
2220gem 'yard' , '~> 0.9.25' , platforms : not_jruby
2321
22+ if Gem ::Version . new ( RUBY_VERSION ) >= Gem ::Version . new ( '2.4' )
23+ gem 'honeybadger' , '>= 2.0'
24+ end
25+
2426if Gem ::Version . new ( RUBY_VERSION ) >= Gem ::Version . new ( '2.6' )
2527 gem 'rubocop' , '~> 1.32.0'
2628 gem 'rubocop-rspec' , '~> 2.12'
Original file line number Diff line number Diff line change 11# frozen_string_literal: true
22
3- require 'honeybadger/ruby'
4-
53RSpec . describe Faulty ::Events ::HoneybadgerListener do
64 let ( :circuit ) { Faulty ::Circuit . new ( 'test_circuit' ) }
75 let ( :error ) { StandardError . new ( 'fail' ) }
119 end
1210
1311 before do
12+ skip 'Honeybadger only supports >= Ruby 2.4' unless Gem ::Version . new ( RUBY_VERSION ) >= Gem ::Version . new ( '2.4' )
13+ require 'honeybadger/ruby'
14+
1415 Honeybadger . configure do |c |
1516 c . backend = 'test'
1617 c . api_key = 'test'
Original file line number Diff line number Diff line change 1919 io . read . strip
2020 end
2121
22+ before do
23+ require 'logger'
24+ end
25+
2226 context 'when Rails is available' do
2327 before do
2428 l = logger
Original file line number Diff line number Diff line change @@ -109,8 +109,8 @@ def faulty_cause(error)
109109 expect { good_redis . ping } . to raise_error do |error |
110110 expect ( error ) . to be_a ( ::Redis ::BaseConnectionError )
111111 expect ( faulty_cause ( error ) ) . to be_a ( Faulty ::Patch ::Redis ::BusyError )
112- expect ( faulty_cause ( error ) . message ) . to eq (
113- ' BUSY Redis is busy running a script. You can only call SCRIPT KILL or SHUTDOWN NOSAVE.'
112+ expect ( faulty_cause ( error ) . message ) . to match (
113+ / BUSY Redis is busy running a script. You can only call SCRIPT KILL or SHUTDOWN NOSAVE/
114114 )
115115 end
116116
You can’t perform that action at this time.
0 commit comments