Branch Coverage

blib/lib/WWW/Scraper/ISBN/Driver.pm
Criterion Covered Total %
branch 34 34 100.0


line true false branch
40 14 21 if (@_)
54 3 1 if (@_)
56 1 2 if $self->verbosity
66 1 22 unless length $isbn == 10 or length $isbn == 13
68 14 8 if (length $isbn == 13) { }
69 2 12 unless $isbn =~ /^(978|979)(\d{10})$/
72 1 7 unless $isbn =~ /^(\d{10}|\d{9}X)$/
87 17 2 if $csum != 0
97 1 15 unless length $ean == 10 or length $ean == 13
99 10 5 if (length $ean == 13) { }
100 1 9 unless $ean =~ /^(?:978|979)(\d{9})\d$/
103 1 4 unless $ean =~ /^(\d{9})[\dX]$/
114 1 12 if $csum == 10
120 1 10 unless my $isbn = shift()
125 1 9 unless $ean
126 1 8 if length $isbn == 13 and $isbn ne $ean
127 2 6 if length $isbn == 10 and $isbn ne $self->convert_to_isbn10($ean)