New issue 39 by schwern: Make a version of $self->expected_tests() that
doesn't output a plan
http://code.google.com/p/test-more/issues/detail?id=39
Right now you can't set the expected number of tests via the public
interface without also outputting a plan. This is because the two were
previously tied together.
Either rework expected_tests() so this is possible, or write a new function
just to set the expected number of tests.
Find points in the code which are accessing $self->{Expected_Tests}
directly and make them use the new method
--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings
_plan_tests() is the only internal method which calls expected_tests()
expecting it
to print the plan out. I've changed that so _plan_tests() calls
_output_plan()
itself (after calling expected_tests()). I then replaced read/writes of
$self->
{Expected_Tests} with calls to expected_plan().
All tests pass, but would code from other modules be calling
expected_tests()
directly? It mightn't be safe to change its behavior if that's happening.
Changes are in http://github.com/gaurav/test-more/tree/issue39.
Thanks for the work, but your suspicion is correct. expected_tests() is a
public
method and documented to print the headers. That behavior can't be changed.