diff options
| author | Mike McQuaid | 2016-09-27 13:32:26 +0100 |
|---|---|---|
| committer | GitHub | 2016-09-27 13:32:26 +0100 |
| commit | 7e93340073106f9f5a4bef057823210fb432c064 (patch) | |
| tree | bd0c814ff2bbfc78743a926c547f5d0d5add7953 /Library | |
| parent | 4488eddf910e3a9e5f7fdbf55055375be13f0ae5 (diff) | |
| parent | cbae10a732f18bd8b96edd114a5aa7904cdbb433 (diff) | |
| download | brew-7e93340073106f9f5a4bef057823210fb432c064.tar.bz2 | |
Merge pull request #1164 from MikeMcQuaid/style-fixups
Rubocop style fixups
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/test/helper/integration_command_test_case.rb | 4 | ||||
| -rw-r--r-- | Library/Homebrew/test/test_audit.rb | 4 | ||||
| -rw-r--r-- | Library/Homebrew/test/test_create.rb | 2 | ||||
| -rw-r--r-- | Library/Homebrew/test/test_custom_command.rb | 4 |
4 files changed, 10 insertions, 4 deletions
diff --git a/Library/Homebrew/test/helper/integration_command_test_case.rb b/Library/Homebrew/test/helper/integration_command_test_case.rb index ab7fcbeaa..2a677e802 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 diff --git a/Library/Homebrew/test/test_audit.rb b/Library/Homebrew/test/test_audit.rb index 98ab780b4..2725f906e 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 diff --git a/Library/Homebrew/test/test_create.rb b/Library/Homebrew/test/test_create.rb index b30e85547..bb1a2cd2a 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 diff --git a/Library/Homebrew/test/test_custom_command.rb b/Library/Homebrew/test/test_custom_command.rb index b3cd39f27..bc27e2121 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}", |
