Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

Ovid (2709)

Ovid
  (email not shown publicly)
http://publius-ovidius.livejournal.com/
AOL IM: ovidperl (Add Buddy, Send Message)

Stuff with the Perl Foundation. A couple of patches in the Perl core. A few CPAN modules. That about sums it up.

Journal of Ovid (2709)

Tuesday July 29, 2008
03:31 AM

Test::Most 0.11

[ #37041 ]

After an earlier discussion of improving the explain function in Test::Most, I've released a new version which basically eliminates the need for using Data::Dumper in most testing. Thus, instead of this:

my $self = Some::Object->new($id);
use Data::Dumper;
explain 'I was just created', Dumper($self);

You can now just do this:

my $self = Some::Object->new($id);
explain 'I was just created:  ', $self;

That output will look similar to:

I was just created: bless( {
    'id' => 2,
    'stack' => []
}, 'Some::Object' )

(Thanks to swillert for improving on my first implementation of this).

Test::Most has now become so powerful that I'm thinking about just making it a dependency of any new software I ship. I can't imagine life without it.

I'm also thinking about the 'failure handler' in Test::Most. Right now it's only internal and allows me to control dieing or bailing out on test failure, but I'd like to expose that. However, I've no idea if anyone would use it. Would it be useful?

Oh, and I also now have co-maintainership of Test::Differences. This is mainly to fix an outstanding bug which has a tiny monkey-patch fix in Test::Most. Barrie Slaymaker has put out an excellent module which doesn't need much help, but if you have suggestions (such as how to implement the screen-width feature), I'm open to them).

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.