Skip to content

Commit

Permalink
Bump faraday version to latest (#946)
Browse files Browse the repository at this point in the history
Bumping required faraday version to v1.0.0 from v0.7.6. This requires
dropping support for Ruby 2.2 - but fixes Ruby 2.7. For details see:

https://github.com/lostisland/faraday/blob/master/CHANGELOG.md#v10
  • Loading branch information
ksylvest committed Jan 29, 2020
1 parent 065cf97 commit 2e4378d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 8 deletions.
5 changes: 0 additions & 5 deletions .travis.yml
Expand Up @@ -10,7 +10,6 @@ branches:
only: [master]

rvm:
- 2.2.10
- 2.3.8
- 2.4.9
- 2.5.7
Expand All @@ -33,10 +32,6 @@ before_install:

matrix:
include:
- rvm: 1.9
env: RAILS_VERSION=4
- rvm: jruby-1.7.27
env: JRUBY_OPTS="--dev" RAILS_VERSION=4
- rvm: jruby-9.2.9.0
env: JRUBY_OPTS="--dev -J-Djruby.launch.inproc=true -J-Xmx1024M" RAILS_VERSION=4
- rvm: jruby-9.2.9.0
Expand Down
2 changes: 1 addition & 1 deletion sentry-raven.gemspec
Expand Up @@ -17,5 +17,5 @@ Gem::Specification.new do |gem|
gem.bindir = "exe"
gem.executables = "raven"

gem.add_dependency "faraday", ">= 0.7.6", "< 1.0"
gem.add_dependency "faraday", ">= 1.0"
end
4 changes: 2 additions & 2 deletions spec/raven/integration_spec.rb
Expand Up @@ -43,15 +43,15 @@
# end

it "timed backoff should prevent sends" do
expect(@instance.client.transport).to receive(:send_event).exactly(1).times.and_raise(Faraday::Error::ConnectionFailed, "conn failed")
expect(@instance.client.transport).to receive(:send_event).exactly(1).times.and_raise(Faraday::ConnectionFailed, "conn failed")
2.times { @instance.capture_exception(build_exception) }
expect(@io.string).to match(/Failed to submit event: ZeroDivisionError: divided by 0$/)
end

it "transport failure should call transport_failure_callback" do
@instance.configuration.transport_failure_callback = proc { |_e| @io.puts "OK!" }

expect(@instance.client.transport).to receive(:send_event).exactly(1).times.and_raise(Faraday::Error::ConnectionFailed, "conn failed")
expect(@instance.client.transport).to receive(:send_event).exactly(1).times.and_raise(Faraday::ConnectionFailed, "conn failed")
@instance.capture_exception(build_exception)
expect(@io.string).to match(/OK!$/)
end
Expand Down

0 comments on commit 2e4378d

Please sign in to comment.