From: Ryan Leavengood Date: 2005-07-02T07:41:58+09:00 Subject: Re: How to use Test::Unit::Assertions from class methods? Michael Schuerig said: > > But how can I use these assertions in a class method? require 'test/unit' class Foo # This: class << self include Test::Unit::Assertions end # OR this: extend Test::Unit::Assertions def self.do_something flunk('Badness') end end Foo::do_something __END__ You will need to rescue on the Test::Unit::AssertionFailedError if you don't want your first failed test taking the whole program down. Ryan