Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixup rubocop warnings #219

Merged
merged 5 commits into from
Aug 21, 2017
Merged
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
28 changes: 14 additions & 14 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ AllCops:
- doc/**/*.rb
- rake.gemspec

Style/LineLength:
Metrics/LineLength:
Enabled: true
Max: 120

Expand All @@ -16,42 +16,42 @@ Style/StringLiterals:
Enabled: true
EnforcedStyle: double_quotes

Style/IndentationWidth:
Style/MultilineIfThen:
Enabled: true

Style/Tab:
Style/MethodDefParentheses:
Enabled: true

Style/EmptyLines:
Style/BracesAroundHashParameters:
Enabled: true

Style/TrailingBlankLines:
Layout/IndentationWidth:
Enabled: true

Style/TrailingWhitespace:
Layout/Tab:
Enabled: true

Style/SpaceBeforeBlockBraces:
Layout/EmptyLines:
Enabled: true

Style/SpaceInsideBlockBraces:
Layout/TrailingBlankLines:
Enabled: true

Style/SpaceInsideHashLiteralBraces:
Layout/TrailingWhitespace:
Enabled: true

Style/CaseIndentation:
Layout/SpaceBeforeBlockBraces:
Enabled: true

Style/MultilineIfThen:
Layout/SpaceInsideBlockBraces:
Enabled: true

Style/MethodDefParentheses:
Layout/SpaceInsideHashLiteralBraces:
Enabled: true

Style/BracesAroundHashParameters:
Layout/CaseIndentation:
Enabled: true

Lint/EndAlignment:
Enabled: true
AlignWith: variable
EnforcedStyleAlignWith: variable
1 change: 1 addition & 0 deletions rake.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,5 @@ Rake has the following features:
s.add_development_dependency(%q<minitest>.freeze)
s.add_development_dependency(%q<rdoc>.freeze)
s.add_development_dependency(%q<coveralls>.freeze)
s.add_development_dependency(%q<rubocop>.freeze)
end
2 changes: 1 addition & 1 deletion test/helper.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# frozen_string_literal: true
$:.unshift File.expand_path("../../lib", __FILE__)

require 'coveralls'
require "coveralls"
Coveralls.wear!

gem "minitest", "~> 5"
Expand Down
2 changes: 1 addition & 1 deletion test/test_rake_file_utils.rb
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ def test_sh_with_hash_option
check_expansion

verbose(false) {
sh "#{RUBY} check_expansion.rb", {chdir: "."}, { verbose: false }
sh "#{RUBY} check_expansion.rb", { chdir: "." }, verbose: false
}
end

Expand Down
4 changes: 2 additions & 2 deletions test/test_rake_rake_test_loader.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ class TestRakeRakeTestLoader < Rake::TestCase
def setup
super

@loader = File.join @rake_lib, 'rake/rake_test_loader.rb'
@loader = File.join @rake_lib, "rake/rake_test_loader.rb"
end

def test_pattern
Expand Down Expand Up @@ -35,7 +35,7 @@ def test_load_error

assert_empty out

no_such_path = File.join @tempdir, 'no_such_test_file'
no_such_path = File.join @tempdir, "no_such_test_file"

expected =
/\A\n
Expand Down
4 changes: 2 additions & 2 deletions test/test_rake_rules.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class TestRakeRules < Rake::TestCase
OBJFILE = "abc.o"
FOOFILE = "foo"
DOTFOOFILE = ".foo"
MINFILE = 'abc.min.o'
MINFILE = "abc.min.o"

def setup
super
Expand Down Expand Up @@ -400,7 +400,7 @@ def obj.find_prereq(task_name)

def test_works_with_chained_extensions_in_rules
create_file(OBJFILE)
rule('.min.o' => ['.o']) do |t|
rule(".min.o" => [".o"]) do |t|
@runs << t.name
assert_equal OBJFILE, t.source
assert_equal MINFILE, t.name
Expand Down