Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .rspec
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
--colour
--color
--warnings
--require spec_helper
103 changes: 103 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
# This is the configuration used to check the rubocop source code.

inherit_from: .rubocop_todo.yml
require:
- rubocop/cop/internal_affairs

AllCops:
Exclude:
- 'vendor/**/*'
- 'spec/fixtures/**/*'
- 'tmp/**/*'
TargetRubyVersion: 2.1

Naming/PredicateName:
# Method define macros for dynamically generated method.
MethodDefinitionMacros:
- define_method
- define_singleton_method
- def_node_matcher
- def_node_search

# Override
Style/BracesAroundHashParameters:
Enabled: false

Style/FrozenStringLiteralComment:
EnforcedStyle: always

Style/FormatStringToken:
# Because we parse a lot of source codes from strings. Percent arrays
# look like unannotated format string tokens to this cop.
Exclude:
- spec/**/*

# Override, less diff
Style/TrailingCommaInArguments:
EnforcedStyleForMultiline: comma

# Override, less diff
Style/TrailingCommaInLiteral:
EnforcedStyleForMultiline: comma

Layout/EndOfLine:
EnforcedStyle: lf

Layout/ClassStructure:
Enabled: true
Categories:
module_inclusion:
- include
- prepend
- extend
ExpectedOrder:
- module_inclusion
- constants
- public_class_methods
- initializer
- instance_methods
- protected_methods
- private_methods

Layout/IndentHeredoc:
EnforcedStyle: powerpack

Lint/AmbiguousBlockAssociation:
Exclude:
- 'spec/**/*.rb'

Lint/InterpolationCheck:
Exclude:
- 'spec/**/*.rb'

Lint/UselessAccessModifier:
MethodCreatingMethods:
- 'def_matcher'
- 'def_node_matcher'

Lint/BooleanSymbol:
Enabled: false

Metrics/BlockLength:
Exclude:
- 'Rakefile'
- '**/*.rake'
- 'spec/**/*.rb'

# Override
Metrics/LineLength:
Max: 120

Metrics/ModuleLength:
Exclude:
- 'spec/**/*.rb'

Performance/Caller:
Exclude:
- spec/rubocop/cop/performance/caller_spec.rb

RSpec/PredicateMatcher:
EnforcedStyle: explicit

RSpec/NestedGroups:
Max: 7
102 changes: 102 additions & 0 deletions .rubocop_todo.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
# This configuration was generated by
# `rubocop --auto-gen-config`
# on 2018-01-20 17:50:24 -0500 using RuboCop version 0.52.1.
# The point is for the user to remove these configuration records
# one by one as the offenses are removed from the code base.
# Note that changes in the inspected code, or installation of new
# versions of RuboCop, may require this file to be generated again.

# Offense count: 76
Metrics/AbcSize:
Max: 18

# Offense count: 42
# Configuration parameters: CountComments.
Metrics/ClassLength:
Max: 174

# Offense count: 195
# Configuration parameters: CountComments.
Metrics/MethodLength:
Max: 14

# Offense count: 7
# Configuration parameters: CountComments.
Metrics/ModuleLength:
Max: 139

# Offense count: 10
RSpec/AnyInstance:
Exclude:
- 'spec/rubocop/cli_spec.rb'
- 'spec/rubocop/cop/lint/duplicate_methods_spec.rb'
- 'spec/rubocop/target_finder_spec.rb'

# Offense count: 1036
# Configuration parameters: Prefixes.
# Prefixes: when, with
RSpec/ContextWording:
Enabled: false

# Offense count: 2845
# Configuration parameters: Max.
RSpec/ExampleLength:
Enabled: false

# Offense count: 43
RSpec/ExpectOutput:
Exclude:
- 'spec/rubocop/cli/cli_auto_gen_config_spec.rb'
- 'spec/rubocop/cli/cli_options_spec.rb'
- 'spec/rubocop/config_spec.rb'
- 'spec/rubocop/cop/cop_spec.rb'
- 'spec/rubocop/formatter/base_formatter_spec.rb'
- 'spec/rubocop/formatter/disabled_config_formatter_spec.rb'
- 'spec/rubocop/formatter/formatter_set_spec.rb'
- 'spec/rubocop/options_spec.rb'
- 'spec/rubocop/path_util_spec.rb'
- 'spec/rubocop/rake_task_spec.rb'
- 'spec/rubocop/result_cache_spec.rb'
- 'spec/rubocop/target_finder_spec.rb'
- 'spec/support/cli_spec_behavior.rb'

# Offense count: 38
# Configuration parameters: EnforcedStyle.
# SupportedStyles: have_received, receive
RSpec/MessageSpies:
Exclude:
- 'spec/rubocop/cli_spec.rb'
- 'spec/rubocop/config_loader_spec.rb'
- 'spec/rubocop/config_store_spec.rb'
- 'spec/rubocop/cop/commissioner_spec.rb'
- 'spec/rubocop/cop/cop_spec.rb'
- 'spec/rubocop/cop/force_spec.rb'
- 'spec/rubocop/cop/generator_spec.rb'
- 'spec/rubocop/formatter/base_formatter_spec.rb'
- 'spec/rubocop/formatter/colorizable_spec.rb'
- 'spec/rubocop/formatter/formatter_set_spec.rb'
- 'spec/rubocop/formatter/progress_formatter_spec.rb'
- 'spec/rubocop/rake_task_spec.rb'

# Offense count: 1
RSpec/MultipleDescribes:
Exclude:
- 'spec/rubocop/string_util_spec.rb'

# Offense count: 921
RSpec/MultipleExpectations:
Max: 25

# Offense count: 21
RSpec/SubjectStub:
Exclude:
- 'spec/rubocop/config_spec.rb'
- 'spec/rubocop/cop/cop_spec.rb'
- 'spec/rubocop/formatter/base_formatter_spec.rb'
- 'spec/rubocop/formatter/json_formatter_spec.rb'
- 'spec/rubocop/formatter/progress_formatter_spec.rb'

# Offense count: 37
# Configuration parameters: IgnoreSymbolicNames.
RSpec/VerifiedDoubles:
Enabled: false
1 change: 0 additions & 1 deletion .rvmrc

This file was deleted.

10 changes: 4 additions & 6 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,8 @@ group :development do
gem 'rubocop', '~> 0.52.1', require: false
end

group :development, :test do
gem 'guard'
gem 'guard-rspec'
gem 'guard-bundler'
gem 'rb-fsevent'
gem 'growl'
group :test do
gem 'coveralls', '~> 0.8.21', require: false
gem 'rspec', '~> 3.5', require: false
gem 'simplecov', '~> 0.14.1', require: false
end
10 changes: 0 additions & 10 deletions Guardfile

This file was deleted.

8 changes: 4 additions & 4 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#!/usr/bin/env rake
require "bundler/gem_tasks"
require 'bundler/gem_tasks'
require 'rspec/core/rake_task'

desc 'Default: run specs.'
task :default => :spec
task default: :spec

desc "Run specs"
desc 'Run specs'
RSpec::Core::RakeTask.new

desc 'Run specs'
task :default => :spec
task default: :spec
4 changes: 0 additions & 4 deletions omniauth-salesforce.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,4 @@ Gem::Specification.new do |gem|
gem.add_dependency 'omniauth', '~> 1.0'
gem.add_dependency 'omniauth-oauth2', '>= 1.5.0'
gem.required_ruby_version = '>= 2.1.0'
gem.add_development_dependency 'rack-test'
gem.add_development_dependency 'rspec', '~> 2.7'
gem.add_development_dependency 'simplecov'
gem.add_development_dependency 'webmock'
end
Loading