pbeckingham has asked for the wisdom of the Perl Monks concerning the following question:

My question is about alternate test harnesses. I have used Test::Harness many times, and am very happy with it.

But I would like to use it to provide users with a means to validate the configuration of my (rather complex) application, environment etc, allowing them to use it to troubleshoot. To do this, I need it to run silently, and report only the problems. It is otherwise just too verbose. I realize this is not the intended use of Test::Harness.

I have not been able to find alternate modules, and before my last resort of writing my own, I would like to hear if anyone knows of a suitable module?

Thank you.

Replies are listed 'Best First'.
Re: Alternate Test::Harness
by chromatic (Archbishop) on Mar 12, 2004 at 03:10 UTC
•Re: Alternate Test::Harness
by merlyn (Sage) on Mar 12, 2004 at 04:32 UTC
Re: Alternate Test::Harness
by TomDLux (Vicar) on Mar 12, 2004 at 03:02 UTC

    Test::Harness is wonderful, but not necessary with Test::More. Simply run the script on its own. There can be complications if the tests are for a module, as they expect to be run from a higher directory. Just remember which directory to be in when you invoke the script

    --
    TTTATCGGTCGTTATATAGATGTTTGCA

Re: Alternate Test::Harness
by seattlejohn (Deacon) on Mar 12, 2004 at 06:22 UTC
    Could you just use Test::Harness and grep out everything except the cases you want to report? (This is my preferred method for viewing test output anyway. I don't want to know about the hundreds of tests that succeeded, just the handful that failed.)

            $perlmonks{seattlejohn} = 'John Clyman';

      I could run Test::Harness and suppress the output, but there's just something about all that interactive counting of tests (and there are 2000 tests) that I don't want to deal with. Just in the way that Test::Harness counts tests from 1 to 10, means that I get unbuffered characters and backspaces sent.

      Test::Harness is too verbose - I agree. I'd rather see a one-line summary on complete success, with no other output. Thanks for the suggestion - it will be "Plan B".

      In fact, thanks to everyone.

Re: Alternate Test::Harness
by esskar (Deacon) on Mar 12, 2004 at 02:49 UTC
    what about Test::More and all the other Test::*s ?
      I'm actually using Test::More now, but that one is for writing the actual tests. I'm interested in the harness that runs and summarizes the tests, rather than the tests themselves.