On 2/26/07, Michael G Schwern <[EMAIL PROTECTED]> wrote:
Also you don't want it to always be true. You want it to reflect whether
the test passed or failed. I presume you still want the extra value even if
the test failed.
Well, at first I didn't think that I'd want it, but after seeing your
* Michael G Schwern <[EMAIL PROTECTED]> [2007-02-25 00:00]:
> You can return a little wrapper
> object like...
>
> # I didn't actually try this
> package Test::Result;
Or use Scalar::Util::dualvar (Perl uses the string value to check
truth so the numeric value may be whatever).
Regar
Mark Fowler wrote:
>
> On 24 Feb 2007, at 22:58, Michael G Schwern wrote:
>
>> Just make sure whatever you return evaluates according to the test
>> pass/fail
>> and not its value and you should be fine. You can return a little
>> wrapper
>> object like...
>
> Or you could just return a referen
On 24 Feb 2007, at 22:58, Michael G Schwern wrote:
Just make sure whatever you return evaluates according to the test
pass/fail
and not its value and you should be fine. You can return a little
wrapper
object like...
Or you could just return a reference to an array with the value in
it
chromatic wrote:
> On Saturday 24 February 2007 06:47, Eric Hacker wrote:
>
>> Is it OK to have the return value from a test be something more than
>> just true when a test passes? Thus the test might be used as a right
>> value in the test script.
>
> Seems like, in general, the semi-predicate p
On Saturday 24 February 2007 06:47, Eric Hacker wrote:
> Is it OK to have the return value from a test be something more than
> just true when a test passes? Thus the test might be used as a right
> value in the test script.
Seems like, in general, the semi-predicate problem. What if the value b
Hello Perl QA Wizards,
I apologize in advance if this is documented somewhere, because I must
have missed it.
Is it OK to have the return value from a test be something more than
just true when a test passes? Thus the test might be used as a right
value in the test script.
Background:
I am work