From: "Douglas A. Seifert" Date: 2007-11-19T02:30:02+09:00 Subject: Re: ruby incredibly slow (update 2) --------------090902040408010402040104 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit > It may come to that but not clear it is file I/O. Yet. Would love to > just get ruby runner to print out the test names as they go by ... > > Ron Jeffries > www.XProgramming.com > > We use something like the following. All of our tests require the following file: test/test_helper.rb: ENV["RAILS_ENV"] = "test" require File.expand_path(File.dirname(__FILE__) + "/../config/environment") require 'test_help' # Show progress by test case class Test::Unit::TestSuite # Runs the tests and/or suites contained in this # TestSuite. def run(result, &progress_block) s = sprintf( "%42s",name) print "\n#{s}: " yield(STARTED, name) @tests.each do |test| test.run(result, &progress_block) end yield(FINISHED, name) end end --------------090902040408010402040104--