aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew
diff options
context:
space:
mode:
authorJack Nagel2013-04-01 12:15:29 -0500
committerJack Nagel2013-04-01 12:15:29 -0500
commitcfe922ffd4c5b21790252e07f40658506e7e414d (patch)
treee376c81edf3a2bca613af991989844acd0e33c92 /Library/Homebrew
parentad5b128fc7b4a36999cce97e62d8939fcf829655 (diff)
downloadbrew-cfe922ffd4c5b21790252e07f40658506e7e414d.tar.bz2
Silence stderr in test suite
Diffstat (limited to 'Library/Homebrew')
-rw-r--r--Library/Homebrew/test/test_bucket.rb10
-rw-r--r--Library/Homebrew/test/test_checksums.rb4
-rw-r--r--Library/Homebrew/test/test_cleaner.rb2
-rw-r--r--Library/Homebrew/test/test_formula.rb6
-rw-r--r--Library/Homebrew/test/test_formula_install.rb4
-rw-r--r--Library/Homebrew/test/test_keg.rb4
6 files changed, 15 insertions, 15 deletions
diff --git a/Library/Homebrew/test/test_bucket.rb b/Library/Homebrew/test/test_bucket.rb
index 0eeb29e74..007c49d7d 100644
--- a/Library/Homebrew/test/test_bucket.rb
+++ b/Library/Homebrew/test/test_bucket.rb
@@ -63,7 +63,7 @@ class BeerTasting < Test::Unit::TestCase
end
def test_zip
- nostdout { assert_nothing_raised { TestZip.new.brew {} } }
+ shutup { assert_nothing_raised { TestZip.new.brew {} } }
end
# needs resurrecting
@@ -80,7 +80,7 @@ class BeerTasting < Test::Unit::TestCase
require 'cmd/prune'
require 'cleaner'
- nostdout do
+ shutup do
assert_nothing_raised do
f=TestBallWithRealPath.new
Homebrew.info_formula f
@@ -103,7 +103,7 @@ class BeerTasting < Test::Unit::TestCase
f3.instance_eval { @version = Version.new("0.3") }
f3.active_spec.instance_eval { @version = Version.new("0.3") }
- nostdout do
+ shutup do
f1.brew { f1.install }
f2.brew { f2.install }
f3.brew { f3.install }
@@ -113,7 +113,7 @@ class BeerTasting < Test::Unit::TestCase
assert f2.installed?
assert f3.installed?
- nostdout do
+ shutup do
Homebrew.cleanup_formula f3
end
@@ -134,7 +134,7 @@ class BeerTasting < Test::Unit::TestCase
end
def test_pathname_plus_yeast
- nostdout do
+ shutup do
assert_nothing_raised do
assert !Pathname.getwd.rmdir_if_possible
assert !Pathname.getwd.abv.empty?
diff --git a/Library/Homebrew/test/test_checksums.rb b/Library/Homebrew/test/test_checksums.rb
index 62e9d5e61..b5549e801 100644
--- a/Library/Homebrew/test/test_checksums.rb
+++ b/Library/Homebrew/test/test_checksums.rb
@@ -3,12 +3,12 @@ require 'test/testball'
class ChecksumTests < Test::Unit::TestCase
def good_checksum f
- assert_nothing_raised { nostdout { f.brew {} } }
+ assert_nothing_raised { shutup { f.brew {} } }
end
def bad_checksum f
assert_raises ChecksumMismatchError do
- nostdout { f.brew {} }
+ shutup { f.brew {} }
end
end
diff --git a/Library/Homebrew/test/test_cleaner.rb b/Library/Homebrew/test/test_cleaner.rb
index a55a30887..c0e767460 100644
--- a/Library/Homebrew/test/test_cleaner.rb
+++ b/Library/Homebrew/test/test_cleaner.rb
@@ -20,7 +20,7 @@ end
class CleanerTests < Test::Unit::TestCase
def test_clean_file
f = CleanerTestBall.new
- nostdout { f.brew { f.install } }
+ shutup { f.brew { f.install } }
assert_nothing_raised { Cleaner.new f }
assert_equal 0100555, (f.bin/'a.out').stat.mode
diff --git a/Library/Homebrew/test/test_formula.rb b/Library/Homebrew/test/test_formula.rb
index 8decb8d08..33b59f93e 100644
--- a/Library/Homebrew/test/test_formula.rb
+++ b/Library/Homebrew/test/test_formula.rb
@@ -13,7 +13,7 @@ class FormulaTests < Test::Unit::TestCase
include VersionAssertions
def test_prefix
- nostdout do
+ shutup do
TestBall.new.brew do |f|
assert_equal File.expand_path(f.prefix), (HOMEBREW_CELLAR+f.name+'0.1').to_s
assert_kind_of Pathname, f.prefix
@@ -47,12 +47,12 @@ class FormulaTests < Test::Unit::TestCase
f=MostlyAbstractFormula.new
assert_equal '__UNKNOWN__', f.name
assert_raises(RuntimeError) { f.prefix }
- nostdout { assert_raises(RuntimeError) { f.brew } }
+ shutup { assert_raises(RuntimeError) { f.brew } }
end
def test_mirror_support
HOMEBREW_CACHE.mkpath unless HOMEBREW_CACHE.exist?
- nostdout do
+ shutup do
f = TestBallWithMirror.new
_, downloader = f.fetch
assert_equal f.url, "file:///#{TEST_FOLDER}/bad_url/testball-0.1.tbz"
diff --git a/Library/Homebrew/test/test_formula_install.rb b/Library/Homebrew/test/test_formula_install.rb
index aad51b623..b63c1f9ee 100644
--- a/Library/Homebrew/test/test_formula_install.rb
+++ b/Library/Homebrew/test/test_formula_install.rb
@@ -31,7 +31,7 @@ end
class InstallTests < Test::Unit::TestCase
def temporary_install f
# Brew and install the given formula
- nostdout do
+ shutup do
f.brew { f.install }
end
@@ -80,7 +80,7 @@ class InstallTests < Test::Unit::TestCase
f=TestScriptFileFormula.new
temporary_install f do
- nostdout do
+ shutup do
f.brew { f.install }
end
diff --git a/Library/Homebrew/test/test_keg.rb b/Library/Homebrew/test/test_keg.rb
index e4fa4f277..3081381aa 100644
--- a/Library/Homebrew/test/test_keg.rb
+++ b/Library/Homebrew/test/test_keg.rb
@@ -43,14 +43,14 @@ class LinkTests < Test::Unit::TestCase
def test_linking_fails_when_already_linked
@keg.link
assert_raise RuntimeError, "Cannot link testball" do
- @keg.link
+ shutup { @keg.link }
end
end
def test_linking_fails_when_files_exist
FileUtils.touch HOMEBREW_PREFIX/"bin/helloworld"
assert_raise RuntimeError do
- @keg.link
+ shutup { @keg.link }
end
end