Subject: | Test::Unit::Procedural minor or major bug |
I started using PerlUnit today, and in
Test::Unit::Procedural the set_up sub gets called twice,
instead of set_up and then tear_down.
In Procedural.pm, lines 66 and following read:
my @set_up_candidates = grep /::set_up$/, $st->functions;
$set_up_func = \&{$set_up_candidates[0]} if @set_up_candidates;
my @tear_down_candidates = grep /::tear_down$/, $st->functions;
$tear_down_func = \&{$set_up_candidates[0]} if @set_up_candidates;
But the last one should obviously be
$tear_down_func = \&{$tear_down_candidates[0]} if @tear_down_candidates;