From 47fe231552c56989fa1f530b1817aafa4c31dff3 Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Tue, 27 Sep 2016 13:02:07 +0100 Subject: [PATCH 1/4] test/helper/integration_command_test_case: fix rubocop style. --- Library/Homebrew/test/helper/integration_command_test_case.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Library/Homebrew/test/helper/integration_command_test_case.rb b/Library/Homebrew/test/helper/integration_command_test_case.rb index ab7fcbeaa0..2a677e8026 100644 --- a/Library/Homebrew/test/helper/integration_command_test_case.rb +++ b/Library/Homebrew/test/helper/integration_command_test_case.rb @@ -76,7 +76,9 @@ class IntegrationCommandTestCase < Homebrew::TestCase ENV["HOMEBREW_BREW_FILE"] = HOMEBREW_PREFIX/"bin/brew" ENV["HOMEBREW_INTEGRATION_TEST"] = cmd_id_from_args(args) ENV["HOMEBREW_TEST_TMPDIR"] = TEST_TMPDIR - env.each_pair { |k, v| ENV[k] = v } + env.each_pair do |k, v| + ENV[k] = v + end read, write = IO.pipe begin From 776785459be67096efd0331c2d69f6133ab18dff Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Tue, 27 Sep 2016 13:02:07 +0100 Subject: [PATCH 2/4] test/test_audit: fix rubocop style. --- Library/Homebrew/test/test_audit.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Library/Homebrew/test/test_audit.rb b/Library/Homebrew/test/test_audit.rb index 98ab780b42..2725f906e3 100644 --- a/Library/Homebrew/test/test_audit.rb +++ b/Library/Homebrew/test/test_audit.rb @@ -67,7 +67,9 @@ class FormulaAuditorTests < Homebrew::TestCase def formula_auditor(name, text, options = {}) path = Pathname.new "#{@dir}/#{name}.rb" - path.open("w") { |f| f.write text } + path.open("w") do |f| + f.write text + end FormulaAuditor.new Formulary.factory(path), options end From 0c472ea6d9a5f96775c52d484064dddb871043e7 Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Tue, 27 Sep 2016 13:02:07 +0100 Subject: [PATCH 3/4] test/test_create: fix rubocop style. --- Library/Homebrew/test/test_create.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Library/Homebrew/test/test_create.rb b/Library/Homebrew/test/test_create.rb index b30e855478..bb1a2cd2af 100644 --- a/Library/Homebrew/test/test_create.rb +++ b/Library/Homebrew/test/test_create.rb @@ -7,6 +7,6 @@ class IntegrationCommandTestCreate < IntegrationCommandTestCase formula_file = CoreTap.new.formula_dir/"testball.rb" assert formula_file.exist?, "The formula source should have been created" - assert_match %(sha256 "#{TESTBALL_SHA256}"), formula_file.read + assert_match %Q(sha256 "#{TESTBALL_SHA256}"), formula_file.read end end From cbae10a732f18bd8b96edd114a5aa7904cdbb433 Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Tue, 27 Sep 2016 13:02:07 +0100 Subject: [PATCH 4/4] test/test_custom_command: fix rubocop style. --- Library/Homebrew/test/test_custom_command.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Library/Homebrew/test/test_custom_command.rb b/Library/Homebrew/test/test_custom_command.rb index b3cd39f276..bc27e2121e 100644 --- a/Library/Homebrew/test/test_custom_command.rb +++ b/Library/Homebrew/test/test_custom_command.rb @@ -6,7 +6,9 @@ class IntegrationCommandTestCustomCommand < IntegrationCommandTestCase cmd = "int-test-#{rand}" file = "#{path}/brew-#{cmd}" - File.open(file, "w") { |f| f.write "#!/bin/sh\necho 'I am #{cmd}'\n" } + File.open(file, "w") do |f| + f.write "#!/bin/sh\necho 'I am #{cmd}'\n" + end FileUtils.chmod 0777, file assert_match "I am #{cmd}",