Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Redis CPAN distribution.

Report information
The Basics
Id: 65971
Status: resolved
Priority: 0/
Queue: Redis

People
Owner: melo [...] cpan.org
Requestors: JNW [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 1.902
Fixed in: (no value)



Subject: subtests should say done_testing(); when done
The attached patch fixes error messages like these: t/10-tie-list.t ... Dubious, test returned 2 (wstat 512, 0x200) Failed 2/6 subtests # Tests were run but no plan was declared and done_testing() was not seen. # Failed test 'direct access' # at /usr/lib/perl5/5.12.1/Test/Builder.pm line 229. # Tests were run but no plan was declared and done_testing() was not seen.
Subject: done_testing.patch
--- Redis-1.902/t/20-tie-hash.t.orig 2011-02-01 10:15:09.000000000 +0100 +++ Redis-1.902/t/20-tie-hash.t 2011-02-21 02:45:25.000000000 +0100 @@ -39,6 +39,7 @@ subtest 'direct access' => sub { is($my_hash{c}++, 'baz', 'get single value ok'); is(++$my_hash{c}, 'bbb', '... even with post/pre-increments'); + done_testing(); }; @@ -57,6 +58,7 @@ subtest 'hash functions' => sub { {foo => 'a', BAR => 'b', bbb => 'c'}, 'reverse() worked' ); + done_testing(); }; --- Redis-1.902/t/10-tie-list.t.orig 2011-02-01 10:15:09.000000000 +0100 +++ Redis-1.902/t/10-tie-list.t 2011-02-21 02:45:34.000000000 +0100 @@ -30,6 +30,7 @@ subtest 'direct access' => sub { is($my_list[2]++, 'baz', 'get single value ok'); is(++$my_list[2], 'bbb', '... even with post/pre-increments'); + done_testing(); }; @@ -65,6 +66,7 @@ subtest 'list functions' => sub { \@my_list, ['foo', 'BAR', 'bbb'],'... original list as expected' ); + done_testing(); };
Yeah, the implicit done_testing() on subtests was added to Test-Simple 0.95_01. I'll bump the dependency on Test::More to next stable version, 0.96. Thanks!