Branch Coverage

lib/Graphics/Toolkit/Color/Space.pm
Criterion Covered Total %
branch 33 56 58.9


line true false branch
19 0 278 if @_ % 2
22 1 277 unless ref $basis
24 0 277 unless ref $shape
26 0 277 unless ref $format
28 15 262 if (ref $args{'format'} eq "HASH")
31 0 30 unless ref $formatter eq "ARRAY" and @$formatter > 0
32 30 0 if exists $formatter->[0] and ref $formatter->[0] eq "CODE"
34 30 0 if exists $formatter->[1] and ref $formatter->[1] eq "CODE"
38 255 22 if (ref $args{'convert'} eq "HASH")
41 0 255 unless ref $converter eq "ARRAY" and @$converter > 1 and ref $converter->[0] eq "CODE" and ref $converter->[1] eq "CODE"
46 15 262 if (ref $args{'values'} eq "HASH")
49 15 0 if ref $numifier->{'read'} eq "CODE" and ref $numifier->{'write'} eq "CODE"
93 696 271 defined $_[1] && exists $_[0]{'convert'}{uc $_[1]} ? :
96 0 257 if not defined $space_name or ref $space_name or ref $from_code ne "CODE" or ref $to_code ne "CODE"
97 0 257 if $self->can_convert($space_name)
98 0 257 if defined $normal and ref $normal ne "HASH"
99 257 0 unless ref $normal
100 0 257 if not exists $normal->{'from'} or exists $normal->{'from'} and not $normal->{'from'}
101 257 0 unless ref $normal->{'from'}
102 0 257 unless exists $normal->{'from'}{'in'}
103 0 257 unless exists $normal->{'from'}{'out'}
104 0 257 if not exists $normal->{'to'} or exists $normal->{'to'} and not $normal->{'to'}
105 257 0 unless ref $normal->{'to'}
106 0 257 unless exists $normal->{'to'}{'in'}
107 0 257 unless exists $normal->{'to'}{'out'}
113 0 212 unless $self->is_value_tuple($values) and defined $space_name and $self->can_convert($space_name)
118 0 196 unless ref $values eq "ARRAY" and defined $space_name and $self->can_convert($space_name)
124 0 269 unless $self->can_convert($space_name) and defined $direction and $direction eq 'from' || $direction eq 'to'