From: Dick Davies Date: 2005-02-02T08:15:32+09:00 Subject: Re: unit/test : I don't want to automatically run all tests * Raphael Bauduin [0251 13:51]: > Hi, > > I'm writing some unit tests and the plan is to let them run each night, and > producing a little > web page summarizing the results. > > I've written my tests, put them in a suite, and want to run them, but > collect the results to build the web page afterwards. I use this code: > > result = Test::Unit::TestResult.new() > MyTestClass.suite.run(result) {|s, name| puts "Status=#{s} and name = > #{name}"} Look at the (source of ) TestTask in rake (http://rake.rubyforge.org), that provides a means of running a named test rather than the lot. -- 'The old 'give em a Linux box and they think they're Jean-Luc Picard' syndrome.' -- Pete Bentley Rasputin :: Jack of All Trades - Master of Nuns