Branch Coverage

blib/lib/WE/Util/Permissions.pm
Criterion Covered Total %
branch 42 60 70.0


line true false branch
75 13 0 if ($args{'-string'}) { }
0 0 elsif ($args{'-file'}) { }
0 0 elsif ($args{'-objectfromfile'}) { }
79 0 0 unless open F, $args{'-file'}
85 0 0 unless open F, $args{'-objectfromfile'}
110 7 84 if $line eq ''
111 10 74 if (my($key, $val) = $line =~ /^!\s*(\S+)\s*:\s*(.+)$/)
112 1 9 if (exists $$directives{$key})
127 0 0 if $@
128 0 0 unless defined $Permissions::_eval_::Def
142 0 1 unless open F, ">$file"
187 9 0 if (ref $usersref eq 'HASH') { }
195 9 0 if (defined $process)
196 6 3 if (defined $page)
198 63 0 exists $groups{$user} ? :
202 28 35 if $self->is_allowed(-'user', $user, @group_arg, @args)
235 199 331 if ($self->_match($subtree->data, $args_ref))
236 140 59 if (@{$subtree->subtree;}) { }
238 75 65 if $r
249 206 326 $$self{'Directives'} && $$self{'Directives'}{'match'} ? :
264 548 57 if ($args_permtype)
266 132 416 ref $args_permtype eq 'ARRAY' ? :
272 41 645 if ($arg =~ /^!(.*)/)
277 611 75 if ($matchtype eq 'glob') { }
74 1 elsif ($matchtype =~ /^(rx|regexp?)$/) { }
281 57 554 if ($arg =~ /[\*\?]/) { }
295 41 644 if ($no) { }
296 21 20 if grep {&$check_sub();} @terms
298 199 444 if grep {&$check_sub();} @terms
314 1 0 if (exists $$self{'Directives'}{$directive}) { }