On Tue, Mar 26, 2002 at 01:47:38PM +0900, Curt Sampson wrote:
> On Mon, 25 Mar 2002, Michael G Schwern wrote:
> 
> > >     2. Skip test of code where dependencies have been tested and found
> > >     to be failing. For example, if the test for the database connection
> > >     module fails, nothing that uses that module should have its test
> > >     run. (The tests should of course be reported as skipped.)
> >
> > Not really a Test::Harness thing, it's up to your test program to do
> > this.  Test::More has facilities to skip blocks of tests or whole test
> > files.  They're explained in the Test::Tutorial.
> 
> Hmm. So you're saying that I should modify my tests to skip themselves
> when they get information that a module they depend on has failed
> its tests? How do you propose I get that information to the test?

You can't.  Not easily.  About all you can do is abort the whole suite
of tests using the "Bail Out" feature of Test::Harness should a Really
Important Thing fail.

    print "Bail out! Database connection failed\n";

and Test::Harness won't run any further test scripts.

Anything of a finer granularity rapidly gets difficult.


> > You can use the callback interface, but it's not stable and is subject
> > to change.  In fact, it probably will.  I still encourage people to
> > use it.
> 
> Well, since I need it for my current method of working, I'll just
> use it and be aware that it will change.

Make sure to give me any feedback about it to I can expand it
according to people's needs.  I'll try to at least document it next
release.


-- 

Michael G. Schwern   <[EMAIL PROTECTED]>    http://www.pobox.com/~schwern/
Perl Quality Assurance      <[EMAIL PROTECTED]>         Kwalitee Is Job One
GOD made us funky!

Reply via email to