From: Travis S. <ai...@us...> - 2007-10-30 22:31:46
|
On Tue, 30 Oct 2007 18:21:58 -0400, "Edward Z. Yang" <edw...@th...> wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Pavel Shevaev wrote: > > $test->filter(array('testFoo', 'testBar')); > > $test->run(); > > > > In this case only 'testFoo', 'testBar' methods should be executed. > > I've implemented something similar to this, but much easier to use (I > think), and with no edits to core code: > > class BaseHarness extends UnitTestCase <snip> > Prefix the test function you want to run by itself with '__only'. I > know double-underscores are reserved, but I think because of the > transient nature of this sort of thing it's a good prefix. Two problems: one, if I want to run a subset of tests, I can't do so from the command line (I have to edit code), and two, it doesn't work for classes not derived from BaseHarness (e.g., the dom tester, which I use extensively). A solution in the core would be really nice. -- Travis In Series maintainer Random coder & quality guy <http://remstate.com/> |