diff options
Diffstat (limited to 'test/mkmf/base.rb')
-rw-r--r-- | test/mkmf/base.rb | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/test/mkmf/base.rb b/test/mkmf/base.rb index b4cf4884fa..0a75744721 100644 --- a/test/mkmf/base.rb +++ b/test/mkmf/base.rb @@ -9,15 +9,22 @@ RbConfig::CONFIG["cppflags"] << " -I." CONFIG["cppflags"] << " -I." $extout_prefix = "$(extout)$(target_prefix)/" -module TestMkmf +class TestMkmf < Test::Unit::TestCase def setup @tmpdir = Dir.mktmpdir @curdir = Dir.pwd @mkmfobj = Object.new Dir.chdir(@tmpdir) + class << (@output = "") + def flush; end + def reopen(*) end + alias write << + end + $stdout = @output end def teardown + $stdout = STDOUT Dir.chdir(@curdir) FileUtils.rm_rf(@tmpdir) end |