While testing test scripts I noticed that their output is defferent
when running directly or under Harness.
I have scripts like this: (called a.t)
use strict;
use warnings;
use Test::More tests => 2;
is(2, 2);
is(2, 3);
and I'd like to test if their output is what I expect.
(These are examples
It is obvious but would be nice if would not happen
use Test::More;
diag explain $data;
works nicely, then if I swicth to
use Test::Most;
diag explain $data;
it stops printing as it now requires TEST_VERBOSE
so Test::Most is not a drop-in replacement for Test::More.
Gabor
If you're struggling to understand a complex app, a graph of the inheritance
hierarchy can be very useful. Here's an example for TAP::Parser:
http://i82.photobucket.com/albums/j275/publius_ovidius/Geek%20Stuff/graph-5.png
It's generated with this code:
#!/usr/bin/env perl
use strict;
On Sunday 15 February 2009 17.49.43 Ovid wrote:
> If you're struggling to understand a complex app, a graph of the
> inheritance hierarchy can be very useful. Here's an example for
> TAP::Parser:
>
> http://i82.photobucket.com/albums/j275/publius_ovidius/Geek%20Stuff/graph-5
>.png
> ...
>
Nice,
Gabor Szabo wrote:
> that is, under Harness there is an extra empty row
> between the not ok line and the explanation line:
> # Failed test at a.t line 7.
>
> Is this intentional?
> If not should this be fixed?
Yes, it is intentional. Its the difference between this:
$ prove ~/tmp/foo.t
/User
Gabor Szabo wrote:
> It is obvious but would be nice if would not happen
>
> use Test::More;
> diag explain $data;
>
> works nicely, then if I swicth to
>
> use Test::Most;
> diag explain $data;
>
> it stops printing as it now requires TEST_VERBOSE
>
>
> so Test::Most is not a drop-in replace
- Original Message
> From: Gabor Szabo
> It is obvious but would be nice if would not happen
>
> use Test::More;
> diag explain $data;
>
> works nicely, then if I swicth to
>
> use Test::Most;
> diag explain $data;
>
> it stops printing as it now requires TEST_VERBOSE
>
>
> so Tes
On Mon, Feb 16, 2009 at 9:17 AM, Ovid wrote:
> - Original Message
>
>> From: Gabor Szabo
>
>> It is obvious but would be nice if would not happen
>>
>> use Test::More;
>> diag explain $data;
>>
>> works nicely, then if I swicth to
>>
>> use Test::Most;
>> diag explain $data;
>>
>> it sto
- Original Message
> From: Gabor Szabo
> Please restore the Test::Simple => Test::More => Test::Most drop in
> replacement chain!
At this point, explain() has been in Test::Most long enough and is one of the
features I pitched it on that I'm not keen on changing it (Dumper was added