http://qs1969.pair.com?node_id=743277

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

Hi, I am unable to see the Test::Harness displaying the test number and also doesn't displays the passed test ie; something like this
ok 1 - use xxxx;
instead I can see only the test that has failed which looks something like this
test1......59/0 # Failed test 'Order updated to PROCEED , Order id(xxxx)' # at test1.t line 565. # got: undef # expected: 'PROCEED'

I am not sure what I changed. I was experimenting with TAP::Harness on another script, but not sure whether it will have impact on the script that I am working which uses TEST::Harness
Note: When I run the test script individually using perl 1.t it displays all the pass and the fail tests with proper number

Replies are listed 'Best First'.
Re: test::harness not displaying passed test
by jethro (Monsignor) on Feb 12, 2009 at 14:17 UTC

    Check out test::harness. Read the part about HARNESS_VERBOSE for info on verbosity. Also read in tap::harness about the parameter 'verbosity', if you set it to 1 you get all the results. Also the parameter 'failures' is relevant.

Re: test::harness not displaying passed test
by ELISHEVA (Prior) on Feb 12, 2009 at 15:17 UTC

    59/0 means that test #59 fails but the total number of tests is (as yet) unknown - implying that you might be using no plan.

    If you declare Test::More or Test::Simple module like use Test::More qw(no_plan) and then run your test script via Test::Harness or prove, the total number of tests prints out as 0 (unknown) except at the very end. See Test::More - I love it when a plan comes together for futher information.

    Best, beth