Skip to content

Commit

Permalink
Update rubocop requirement from ~> 0.87.0 to ~> 0.89.1
Browse files Browse the repository at this point in the history
Updates the requirements on [rubocop](https://github.com/rubocop-hq/rubocop) to permit the latest version.
- [Release notes](https://github.com/rubocop-hq/rubocop/releases)
- [Changelog](https://github.com/rubocop-hq/rubocop/blob/master/CHANGELOG.md)
- [Commits](rubocop/rubocop@v0.87.0...v0.89.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
  • Loading branch information
dependabot-preview[bot] authored and tagliala committed Aug 11, 2020
1 parent b3be441 commit a8743d4
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Layout/LineLength:
Enabled: false

Metrics/AbcSize:
Max: 39.29
Max: 44.11

Metrics/CyclomaticComplexity:
Max: 19
Expand Down
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ end
group :development do
gem 'rake', '~> 13.0'
gem 'rspec', '~> 3.9'
gem 'rubocop', '~> 0.87.0'
gem 'rubocop', '~> 0.89.1'
gem 'rubocop-performance', '~> 1.7'
gem 'rubocop-rspec', '~> 1.41'
gem 'truthy', '~> 1.0'
Expand Down
2 changes: 1 addition & 1 deletion bin/coveralls
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

lib = File.expand_path(File.dirname(__FILE__) + '/../lib')
lib = File.expand_path('../lib', __dir__)
$LOAD_PATH.unshift(lib) if File.directory?(lib) && !$LOAD_PATH.include?(lib)

require 'coveralls'
Expand Down
4 changes: 2 additions & 2 deletions lib/coveralls/api.rb
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ def disable_net_blockers!
begin
require 'webmock'

allow = WebMock::Config.instance.allow || []
WebMock::Config.instance.allow = [*allow].push API_HOST
allow = Array(WebMock::Config.instance.allow)
WebMock::Config.instance.allow = allow.push API_HOST
rescue LoadError
rescue StandardError => e
# TODO: Add error action
Expand Down
2 changes: 1 addition & 1 deletion lib/coveralls/rake/task.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ module Coveralls
class RakeTask < ::Rake::TaskLib
include ::Rake::DSL if defined?(::Rake::DSL)

def initialize(*_args)
def initialize(*_args) # rubocop:disable Lint/MissingSuper
namespace :coveralls do
desc 'Push latest coverage results to Coveralls.io'
task :push do
Expand Down
8 changes: 3 additions & 5 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def setup_formatter

def stub_api_post
body = '{"message":"","url":""}'
stub_request(:post, Coveralls::API::API_BASE + '/jobs').with(
stub_request(:post, "#{Coveralls::API::API_BASE}/jobs").with(
headers: {
'Accept' => '*/*; q=0.5, application/xml',
'Accept-Encoding' => 'gzip, deflate',
Expand All @@ -60,12 +60,10 @@ def stub_api_post
).to_return(status: 200, body: body, headers: {})
end

def silence
def silence(&block)
return yield if ENV['silence'] == 'false'

silence_stream(STDOUT) do
yield
end
silence_stream($stdout, &block)
end

def silence_stream(stream)
Expand Down

0 comments on commit a8743d4

Please sign in to comment.