Skip to content

Commit

Permalink
Disable remaining Rubocop warnings and explode in future
Browse files Browse the repository at this point in the history
  • Loading branch information
Nick Campbell committed Apr 28, 2021
1 parent bea3b52 commit 50499f6
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 7 deletions.
4 changes: 1 addition & 3 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,7 @@ require 'rubocop/rake_task'

namespace :test do
desc 'Runs RuboCop on specified directories'
RuboCop::RakeTask.new(:rubocop) do |task|
task.fail_on_error = false
end
RuboCop::RakeTask.new(:rubocop)
end

Rake::Task[:test].enhance ['test:rubocop']
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module Zaikio
module OAuthClient
class SubscriptionsController < ConnectionsController
def new
def new # rubocop:disable Metrics/MethodLength
opts = params.permit(:client_name, :state, :plan, :organization_id)
opts[:redirect_with_error] = 1
opts[:state] ||= session[:state] = SecureRandom.urlsafe_base64(32)
Expand Down
2 changes: 1 addition & 1 deletion lib/zaikio/oauth_client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ def get_access_token(bearer_id:, client_name: nil, bearer_type: "Person", scopes

# Finds the best usable access token. Note that this token may have expired and
# would require refreshing.
def find_usable_access_token(client_name:, bearer_type:, bearer_id:, requested_scopes:)
def find_usable_access_token(client_name:, bearer_type:, bearer_id:, requested_scopes:) # rubocop:disable Metrics/MethodLength
configuration.logger.debug "Try to fetch token for client_name: #{client_name}, "\
"bearer #{bearer_type}/#{bearer_id}, requested_scopes: #{requested_scopes}"

Expand Down
2 changes: 1 addition & 1 deletion lib/zaikio/oauth_client/authenticatable.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def new
)
end

def approve
def approve # rubocop:disable Metrics/MethodLength,Metrics/AbcSize
if params[:error].present?
redirect_to send(
respond_to?(:error_path_for) ? :error_path_for : :default_error_path_for,
Expand Down
2 changes: 1 addition & 1 deletion lib/zaikio/oauth_client/test_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module OAuthClient
module TestHelper
extend ActiveSupport::Concern

class TestSessionController < ActionController::Base
class TestSessionController < ActionController::Base # rubocop:disable Rails/ApplicationController
def show
if session[params[:key]].nil?
head :no_content
Expand Down

0 comments on commit 50499f6

Please sign in to comment.