Condition Coverage

lib/Class/Usul/Functions.pm
Criterion Covered Total %
condition 93 166 56.0


and 3 conditions

line !l l&&!r l&&r condition
229 110 22 962 defined $v and length $v
231 962 0 0 &is_ntfs() and not -e $v
235 962 0 0 &is_win32() and defined $v
245 92 5 285 $_[0] && ref $_[0] eq 'HASH'
253 154 22 46 defined $v and length $v
176 45 1 defined $v and length $v and -d "$v"
452 0 9 8 not $opts->{'ignore_loaded'} and &is_class_loaded($class)
525 110 0 55 $path = &abs_path(scalar catfile($_, $file)) and -f $path
575 6 0 0 defined $user and not $user =~ / \A \d+ \z /mx
591 5 1 6 $dir ne $dir->parent and not $dir =~ / lib \z /mx
601 354 975 1278 $_[0] && ref $_[0] eq 'ARRAY'
605 12 31 15 $_[0] && ref $_[0] eq 'CODE'
609 30 16 391 $_[0] && ref $_[0] eq 'HASH'
655 173 0 4 exists $dest->{$_} && defined $dest->{$_}
659 118 55 203 not defined $v and defined(my $src = $args[$i++])
694 3 0 3 defined $str and length $str
745 1 2 0 defined $base and not length $base
805 4 0 1468 defined $untainted and $untainted eq $string
818 0 0 2 $io->exists and $io->is_readable
0 0 2 $io->exists and $io->is_readable and $red = $io->read
0 0 2 $io->exists and $io->is_readable and $red = $io->read and $red == $wanted

or 2 conditions

line l !l condition
241 96 1 $_[0] // ''
358 23 0 $_[0] // ''
378 4 0 $_[0] // ''
404 52 0 $_[0] // ''
423 8 2 $args[0] //= ''
431 3 0 $args[0] //= ''
445 0 17 $opts //= {}
469 0 1 $_[1] && $_[1][0] || '<'
470 0 1 $_[1] && $_[1][1] || '>'
540 0 0 &get_user()->gecos // ''
542 0 0 $v //= ''
551 22 0 $dirs || '.'
556 0 22 $ENV{"${env_pref}_CONFIG_LOCAL_SUFFIX"} // '_local'
560 0 22 $extns // [&supported_extensions()]
581 2 0 shift() // ''
643 6 0 &get_user($_[0])->name || 'unknown'
672 2 0 $_[0] // ''
721 11 0 $_[0] // ''
9 2 $_[1] // 0
725 9 0 $_[0] // ''
9 0 $_[1] // 0
729 46 0 $_[0] // ''
733 647 0 $_[0] // ''
737 0 1 $_[0] // 0
739 0 1 (caller $frame)[3] // 'main'
771 1 1 $_[1] // " \t"
2 0 $_[0] // ''
778 0 1 $_[1] && $_[1][0] || '<'
779 0 1 $_[1] && $_[1][1] || '>'
812 0 2 $wanted //= 64
0 2 $opts //= {}
847 2 1 $g //= sub { ; }

or 3 conditions

line l !l&&r !l&&!r condition
281 0 0 10 $c[0] == $pad or $c[1] == $pad
366 9 1 0 $_[0] // &urandom()
370 0 0 0 $_[0] // &urandom()
441 29 0 0 print({$handle;} @args) || &throw('IO error: [_1]', [$Class::Usul::Functions::OS_ERROR])
498 0 22 0 $ENV{'XDG_DATA_HOME'} // catdir($my_home, '.local', 'share')
536 0 0 0 shift() // hostname()
550 22 0 0 $appclass // &throw(Unspecified(), ['application class'], 'level', 2)
577 0 0 6 $user // $Class::Usul::Functions::UID
621 0 0 962 &is_win32() || lc $Class::Usul::Functions::OSNAME eq 'cygwin'
647 0 5 0 $ENV{'USER'} || $ENV{'LOGNAME'} || &loginid($_[0])
698 3 1 2 not $direction or $direction eq 'right'
815 0 2 0 $opts->{'source'} // $default
826 0 0 0 $_[0] // &UUID_PATH()