Branch Coverage

blib/lib/String/Tokenizer.pm
Criterion Covered Total %
branch 44 44 100.0


line true false branch
24 7 3 if @args
44 8 2 if defined $delimiter
46 2 8 if defined $handle_whitespace
52 2 8 if ($self->{'handle_whitespace'}) { }
58 9 1 if ($self->{'delimiter'})
66 60 88 if (/$delimiter/) { }
72 75 121 if ($char =~ /^$delimiter$/) { }
74 31 44 if (defined $token and $token =~ /^.*$/)
88 47 74 unless defined $token
95 16 44 if defined $token
115 1 5 wantarray ? :
130 1 4 unless (caller())[0] eq 'String::Tokenizer'
149 103 5 $self->{'index'} < scalar @{$self->{'tokens'};} ? :
159 1 117 if $self->{'index'} >= scalar @{$self->{'tokens'};}
165 1 25 if $self->{'index'} <= 0
177 3 38 if $self->{'index'} <= 0 or $self->{'index'} >= scalar @{$self->{'tokens'};}
186 1 4 if ($self->lookAheadToken eq $token_to_match)
201 20 3 if ($token ne $token_to_match) { }
209 1 3 unless ($matched)
223 1 2 if ($self->lookAheadToken eq $token_to_match)
235 1 17 if $self->nextToken eq $token_to_match
246 3 1 if $self->lookAheadToken =~ /^\s+$/