Branch Coverage

blib/lib/WWW/Shopify/Liquid/Tag/For.pm
Criterion Covered Total %
branch 54 80 67.5


line true false branch
16 1 93 unless $self->{'arguments'}[0]->isa('WWW::Shopify::Liquid::Operator::In')
19 0 93 unless $self->{'arguments'}[0]{'operands'}[0] and $self->{'arguments'}[0]{'operands'}[0]->isa('WWW::Shopify::Liquid::Token::Variable') and int @{$self->{'arguments'}[0]{'operands'}[0]{'core'};} == 1 and $self->{'arguments'}[0]{'operands'}[0]{'core'}[0]->isa('WWW::Shopify::Liquid::Token::String')
46 0 94 unless $token
48 3 91 if (int @tokens > 0)
49 0 3 if int @tokens > 1 or $tokens[0][0]->tag ne 'else'
62 3 44 if ($renderer->state and exists $renderer->state->{'values'}{$self . '-1'})
77 7 428 if (my $exp = $@)
78 7 0 if (defined $exp and &blessed($exp) and $exp->isa('WWW::Shopify::Liquid::Exception::Control')) { }
79 3 4 if ($exp->isa('WWW::Shopify::Liquid::Exception::Control::Pause')) { }
86 2 2 if $exp->initial_render and int @{$exp->initial_render;} > 0
87 2 2 if ($exp->isa('WWW::Shopify::Liquid::Exception::Control::Break')) { }
2 0 elsif ($exp->isa('WWW::Shopify::Liquid::Exception::Control::Continue')) { }
97 0 428 unless $self->is_processed($content)
101 44 0 if $all_processed
107 10 61 &blessed($result) && $result->isa('WWW::Shopify::Liquid::Operator::Concatenate') ? :
118 0 7 if $start > $end
128 0 49 $self->is_processed($self->{'contents'}) ? :
130 0 49 if (my $exp = $@)
131 0 0 if (defined $exp and &blessed($exp) and $exp->isa('WWW::Shopify::Liquid::Exception::Control')) { }
132 0 0 if $exp->initial_render and int @{$exp->initial_render;} > 0
133 0 0 if ($exp->isa('WWW::Shopify::Liquid::Exception::Control::Break')) { }
0 0 elsif ($exp->isa('WWW::Shopify::Liquid::Exception::Control::Continue')) { }
146 0 7 if int @parts == 1
153 1 65 if ref $operand eq 'HASH'
164 67 0 unless $self->is_processed($op2)
166 8 58 if $self->is_processed($op2) and $action eq 'optimize'
167 13 53 if ($action eq 'optimize' and not $self->is_processed($self->{'contents'}))
175 0 1 if int @{$_->{'arguments'}[0]{'operands'}[0]{'core'};} == 1 and &blessed($_->{'arguments'}[0]{'operands'}[0]{'core'}[0]{'core'}) and $_->{'arguments'}[0]{'operands'}[0]{'core'}[0]{'core'}->isa('WWW::Shopify::Liquid::Token::String')
183 5 61 if not $self->is_processed($op2) and $action eq 'optimize'
184 0 61 if not $self->is_processed($op2) and $action eq 'render'
185 1 6 defined $self->{'false_path'} ? :
7 54 if ref $op2 ne 'ARRAY' or int @$op2 == 0
186 0 54 unless ref $op2 eq 'ARRAY'
193 2 54 if $_->isa('WWW::Shopify::Liquid::Token::Variable::Named')
194 1 53 if $limit_arg
195 0 54 unless $self->is_processed($limit_result)
196 1 0 if $limit_result and ref $limit_result and ref $limit_result eq 'HASH' and &looks_like_number($limit_result->{'limit'})
199 2 54 if $_->isa('WWW::Shopify::Liquid::Token::Variable::Named')
200 1 53 if $offset_arg
201 1 0 if $offset_result and ref $offset_result and ref $offset_result eq 'HASH' and &looks_like_number($offset_result->{'offset'})