| 1 | package TestHelper::Plugin::RepeatFoo; | ||||||||||||
| 2 | |||||||||||||
| 3 | 2 | ▶ | use Moo; | ||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||
| 4 | 2 | extends 'Code::TidyAll::Plugin'; | |||||||||||
| 5 | |||||||||||||
| 6 | 2 | has 'times' => ( is => 'ro' ); | |||||||||||
| 7 | |||||||||||||
| 8 | 2 | ▶ | sub transform_source { | ||||||||||
|
Subroutine
transform_source: called CC=2 SCAR=7.1
Pod
documented
| |||||||||||||
| 9 | 2 | my ( $self, $source ) = @_; | |||||||||||
| 10 | 2 | ▶ | my $times = $self->times || die "no times specified"; | ||||||||||
|
Condition50%1/2
$self->times || die('no times specified')
MC/DC0%0/1
$self->times || die('no times specified')
$self->times
Truth table50%1/2
A
A= $self->times
| |||||||||||||
| 11 | 2 | return $source x $times; | |||||||||||
| 12 | } | ||||||||||||
| 13 | |||||||||||||
| 14 | 2 | 1; | |||||||||||