I'm not very experienced with Test::* type modules.
I'm using Test::More, but I'm not attached.
If there is some otehr test module that solves the below problems, I
will switch.
First thing, when I run Test::More and there are problems,
I get a summary report at the end like:
# Looks like you planned 22 tests but ran 23.
# Looks like you failed 1 test of 23 run.
Is there a way to tell it to always print out some sort of summary
report
even if everything passed? like "23 pass out of 23 tests" or something.
Another issue I'm running into is that I'm doing a lot of negative
testing.
I'm testing a module I wrote and making sure it errors out when given
bad data.
According to Test::More, the way to do that is:
ok !eval {myfun("bad", "data"); 1}, 'test bad data';
The annoying thing is that myfunc() prints out a bunch of error messages
which show up on my terminal when I run mytest.pl script.
So, I run mytest.pl, see a bunch of errors, and it's not immediately
clear
those messages are expected.
Is there a way to get Test::More or some other test module to capture
stdout and stderr and NOT print it out when I expect an error?
If a check fails, it oculd print out the last thing to go to stderr
but if it passes, it would be nice if my terminal wasn't full of
ERROR messages.
Thanks,
Greg
_______________________________________________
Boston-pm mailing list
[email protected]
https://mail.pm.org/mailman/listinfo/boston-pm