From: nathaniel@... Date: 2003-01-11T00:49:45+09:00 Subject: Re: Test::Unit fails w/no tests [was: testunit 0.1.6 problems] dblack@candle.superlink.net wrote: > I think what I had in mind was a little different. Let's say > every empty test actually runs the #no_test method. That > means that this: > > def test_1 > end > > and this: > > def test_1 > no_test > end > > are effectively the same. > > The idea would then be: by overriding #no_test, you could > change the behavior, without having to change all the empty > tests themselves. Well, what's being discussed is actually empty test suites, not empty tests. So this is a failure: def TC < Test::UnitTestCase end But this is not: def TC < Test::Unit::TestCase def test_1 end end That said, I do think I can go the direction you're talking about and make it so that one little tweak to the framework will change this globally, as opposed to having to silence things on an individual basis. Perhaps: require 'test/unit/testcase' module Test module Unit class TestCase def default_test end end end end You could throw something like that in a file and require it in your tests to silence the warning. Or, if you wanted to, you could do a check of your own instead. Anyhow, that's what I'm currently thinking. It is, of course, subject to change when I actually get around to implementing it :-) Nathaniel <:((>< + - - | RoleModel Software, Inc. | EQUIP VI