Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Fix rubocop warnings * Fix rspec warnings * Update flay score
- Loading branch information
Showing
12 changed files
with
154 additions
and
100 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
AllCops: | ||
Include: | ||
- 'Gemfile' | ||
Exclude: | ||
- 'vendor/**/*' | ||
- 'benchmarks/**/*' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
--- | ||
threshold: 12 | ||
total_score: 74 | ||
total_score: 72 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,113 @@ | ||
inherit_from: ../.rubocop.yml | ||
|
||
# Avoid parameter lists longer than five parameters. | ||
ParameterLists: | ||
Max: 3 | ||
CountKeywordArgs: true | ||
|
||
# Avoid more than `Max` levels of nesting. | ||
BlockNesting: | ||
Max: 3 | ||
|
||
# Align with the style guide. | ||
CollectionMethods: | ||
PreferredMethods: | ||
collect: 'map' | ||
inject: 'reduce' | ||
find: 'detect' | ||
find_all: 'select' | ||
|
||
# Do not force public/protected/private keyword to be indented at the same | ||
# level as the def keyword. My personal preference is to outdent these keywords | ||
# because I think when scanning code it makes it easier to identify the | ||
# sections of code and visually separate them. When the keyword is at the same | ||
# level I think it sort of blends in with the def keywords and makes it harder | ||
# to scan the code and see where the sections are. | ||
AccessModifierIndentation: | ||
Enabled: false | ||
|
||
# Limit line length | ||
LineLength: | ||
Max: 106 | ||
|
||
# Disable documentation checking until a class needs to be documented once | ||
Documentation: | ||
Enabled: false | ||
|
||
# Do not always use &&/|| instead of and/or. | ||
AndOr: | ||
Enabled: false | ||
|
||
# Do not favor modifier if/unless usage when you have a single-line body | ||
IfUnlessModifier: | ||
Enabled: false | ||
|
||
# Allow case equality operator (in limited use within the specs) | ||
CaseEquality: | ||
Enabled: false | ||
|
||
# Constants do not always have to use SCREAMING_SNAKE_CASE | ||
ConstantName: | ||
Enabled: false | ||
|
||
# Not all trivial readers/writers can be defined with attr_* methods | ||
TrivialAccessors: | ||
Enabled: false | ||
|
||
# Allow empty lines around class body | ||
EmptyLinesAroundClassBody: | ||
Enabled: false | ||
|
||
# Allow empty lines around module body | ||
EmptyLinesAroundModuleBody: | ||
Enabled: false | ||
|
||
# Allow empty lines around block body | ||
EmptyLinesAroundBlockBody: | ||
Enabled: false | ||
|
||
# Allow multiple line operations to not require indentation | ||
MultilineOperationIndentation: | ||
Enabled: false | ||
|
||
# Prefer String#% over Kernel#sprintf | ||
FormatString: | ||
Enabled: false | ||
|
||
# Use square brackets for literal Array objects | ||
PercentLiteralDelimiters: | ||
PreferredDelimiters: | ||
'%': '{}' | ||
'%i': '[]' | ||
'%q': () | ||
'%Q': () | ||
'%r': '{}' | ||
'%s': () | ||
'%w': '[]' | ||
'%W': '[]' | ||
'%x': () | ||
|
||
# Align if/else blocks with the variable assignment | ||
EndAlignment: | ||
AlignWith: variable | ||
|
||
# Do not always align parameters when it is easier to read | ||
AlignParameters: | ||
Exclude: | ||
- spec/**/*_spec.rb | ||
|
||
# Prefer #kind_of? over #is_a? | ||
ClassCheck: | ||
EnforcedStyle: kind_of? | ||
|
||
# Do not prefer double quotes to be used when %q or %Q is more appropriate | ||
UnneededPercentQ: | ||
Enabled: false | ||
|
||
# Allow a maximum ABC score | ||
Metrics/AbcSize: | ||
Max: 21.02 | ||
|
||
# Do not prefer lambda.call(...) over lambda.(...) | ||
LambdaCall: | ||
Enabled: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,6 @@ | ||
# encoding: utf-8 | ||
|
||
require 'request' | ||
require 'devtools' | ||
Devtools.init_spec_helper | ||
require 'request' | ||
|
||
RSpec.configure do |config| | ||
end | ||
Devtools.init_spec_helper |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters