Branch Coverage

blib/lib/Image/ExifTool/WritePhotoshop.pl
Criterion Covered Total %
branch 44 74 59.4


line true false branch
21 0 66 if (defined $setName)
23 0 0 if ($$valPt =~ m[.*/#(.{0,255})#/$]s) { }
0 0 elsif ($setName eq '1') { }
34 0 0 if length $name & 1
48 45 30 unless $et
50 19 11 unless ($dataPt)
77 24 66 if ($pos ^ $start) & 1
79 0 90 unless ($type =~ /^(8BIM|PHUT|DCSR|AgHg|MeSa)$/)
87 90 0 if $namelen & 1
88 0 90 if ($pos + $namelen + 10 > $dirEnd)
96 0 90 if ($size + $pos > $dirEnd)
101 3 87 if ($newTags->{$tagID} and $type eq '8BIM') { }
109 0 3 if (not $isOverwriting and $tagInfo eq $Image::ExifTool::Photoshop::iptcDigestInfo)
110 0 0 if (grep /^new$/, @{$$nvHash{"DelValue"};})
112 0 0 if $et->{'NewIPTCDigest'} and $et->{'NewIPTCDigest'} eq $value
114 0 0 if (grep /^old$/, @{$$nvHash{"DelValue"};})
116 0 0 if $et->{'OldIPTCDigest'} and $et->{'OldIPTCDigest'} eq $value
119 3 0 if ($isOverwriting)
123 0 3 if ($tagInfo eq $Image::ExifTool::Photoshop::iptcDigestInfo) { }
130 0 3 unless defined $value
136 87 0 if ($type eq "8BIM")
138 76 11 unless ($tagInfo)
145 22 0 if ($tmpInfo and $tmpInfo->{'SubDirectory'} and $tmpInfo->{'SubDirectory'}{'TagTable'} ne 'Image::ExifTool::Exif::Main' || $et->{'FILE_TYPE'} eq 'PSD' && ($editDirs->{'1028'} || $editDirs->{'1060'}))
150 18 4 if $table->{'WRITE_PROC'}
154 29 58 if ($tagInfo) { }
155 8 21 if $addDirs->{$tagID}
166 27 2 if (defined $newValue) { }
167 2 25 unless length $newValue
180 32 56 if $newSize & 1
189 21 21 if ($newTags->{$tagID}) { }
194 1 20 if ($tagInfo eq $Image::ExifTool::Photoshop::iptcDigestInfo and defined $value) { }
195 1 0 if ($value eq 'new') { }
0 0 elsif ($value eq 'old') { }
203 4 16 unless $nvHash->{'IsCreating'}
205 0 17 unless defined $value
217 0 21 unless $value
224 21 17 if $size & 1