Branch Coverage

blib/lib/PONAPI/DAO/Request/Role/HasDataMethods.pm
Criterion Covered Total %
branch 21 22 95.4


line true false branch
10 80 5 if $self->check_data_has_type and $self->check_data_type_match and $self->check_data_attributes
20 1 85 if ref($_ || '') ne 'HASH'
23 2 83 unless exists $_->{'type'}
34 3 41 unless $_->{'type'} eq $self->type
45 45 36 unless $e and exists $e->{'attributes'}
46 2 34 unless $self->repository->type_has_fields($type, [keys %{$$e{'attributes'};}])
60 67 12 unless $e and exists $e->{'relationships'}
62 12 0 if (%{$e->{'relationships'};})
64 2 13 if (not $self->repository->has_relationship($type, $rel_type)) { }
1 19 elsif (not $self->repository->has_one_to_many_relationship($type, $rel_type) and ref $e->{'relationships'}{$rel_type} eq 'ARRAY' and @{$e->{'relationships'}{$rel_type};} > 1) { }
87 115 178 ref $self->data eq 'ARRAY' ? :