Branch Coverage

blib/lib/Jemplate.pm
Criterion Covered Total %
branch 44 134 32.8


line true false branch
82 0 3 if ($runtime)
84 0 0 unless $compile
88 0 3 unless @$templates
90 3 0 if ($list)
97 0 0 if ($compile)
102 0 0 if ($content)
122 1 5 exists $ENV{'JEMPLATE_START_TAG'} ? :
125 1 5 exists $ENV{'JEMPLATE_END_TAG'} ? :
128 0 6 exists $ENV{'JEMPLATE_PRE_CHOMP'} ? :
131 0 6 exists $ENV{'JEMPLATE_POST_CHOMP'} ? :
134 0 6 exists $ENV{'JEMPLATE_TRIM'} ? :
137 0 6 exists $ENV{'JEMPLATE_ANYCASE'} ? :
140 0 6 exists $ENV{'JEMPLATE_EVAL_JAVASCRIPT'} ? :
150 0 6 unless GetOptions 'compile|c', \$compile, 'list|l', \$list, 'runtime|r:s', \$runtime, 'start-tag=s', \$start_tag, 'end-tag=s', \$end_tag, 'trim=s', \$trim, 'pre-chomp', \$pre_chomp, 'post-chomp', \$post_chomp, 'any-case', \$anycase, 'eval!', \$eval_javascript, 'source|s', \$source, 'exclude=s', \$exclude, 'ajax:s', \$ajax, 'json:s', \$json, 'xxx', \$xxx, 'xhr:s', \$xhr, 'compact', \$compact, 'minify:s', \$minify, 'help|?', \$help
177 0 6 if ($help)
181 0 36 defined $_ && !length($_) ? :
182 0 6 if $runtime and $runtime eq 1
184 0 6 if defined $runtime and not grep({$runtime =~ /$_/;} 'standard', 'lite', 'jquery', 'yui', 'legacy')
185 0 3 if $list and $runtime || $compile
186 0 3 unless $list or $runtime or $compile
188 3 0 $list ? :
3 3 $compile ? :
0 6 $runtime ? :
195 2 4 if defined $start_tag
196 2 4 if defined $end_tag
197 0 6 if defined $pre_chomp
198 0 6 if defined $post_chomp
199 0 6 if defined $trim
200 0 6 if defined $anycase
201 6 0 if defined $eval_javascript
216 0 0 unless open F, '<', $filepath
228 0 10 if (m[/\.[^\.]+]) { }
242 3 5 unless (-e $arg)
243 0 5 unless (-s $arg or -d $arg)
244 0 5 if ($exclude and $arg =~ /$exclude/)
246 2 3 if (-d $arg) { }
265 0 0 if @_
274 0 0 unless @_
276 0 0 defined $_ ? :
278 0 0 $compact ? :
280 0 0 if ($runtime eq 'standard') { }
0 0 elsif ($runtime eq 'jquery') { }
0 0 elsif ($runtime eq 'yui') { }
0 0 elsif ($runtime eq 'legacy') { }
0 0 elsif ($runtime eq 'lite') { }
301 0 0 if $ajax eq 1
302 0 0 if $ajax eq 'xhr'
303 0 0 if $json eq 1
304 0 0 if $xhr eq 1
308 0 0 if $runtime
310 0 0 if $json =~ /^json2?$/i
312 0 0 if $ajax eq 'xhr'
313 0 0 if $ajax eq 'jquery'
314 0 0 if $ajax eq 'yui'
316 0 0 if $json =~ /^json2?$/i
317 0 0 if $json =~ /^json2?[_-]?internal$/i
318 0 0 if $json eq 'yui'
320 0 0 if $xhr eq 'ilinsky'
321 0 0 if $xhr eq 'gregory'
323 0 0 if $xxx
337 0 0 unless my $result = $self->compile_template_files(@$template_file_paths)
339 0 0 unless open MODULE, "> $module_path"
349 0 0 unless grep {-M $_ < $m;} @$template_file_paths
359 0 0 unless open FILE, $filepath
370 0 15 unless @_ == 3
373 6 9 ref $self ? :
374 1 14 unless my $parse_tree = $parser->parse($template_content, {'name', $template_name})