Branch Coverage

blib/lib/Finance/Bank/ID/Mandiri.pm
Criterion Covered Total %
branch 97 176 55.1


line true false branch
72 0 0 if $i->{'readonly'}
80 1 0 unless $self->site
81 1 0 unless $self->https_host
87 0 0 if $self->logged_in
88 0 0 unless $self->username
89 0 0 unless $self->password
97 0 0 unless $mech->content =~ /LoginForm/
110 0 0 if $mech->content =~ m[<font class="errorMessage">(.+?)</font>]
111 0 0 if $mech->content =~ /<frame\s.+Welcome/
112 0 0 if $mech->content =~ m[<font class="alert">(\w.+?)</font>]
113 0 0 if $mech->content =~ /LoginForm/
123 0 0 unless $mech->content =~ /SELAMAT DATANG/
134 0 0 unless $self->logged_in
145 0 0 if $retrieve
148 0 0 unless $ct =~ /(HISTORI TRANSAKSI|MUTASI REKENING)/
150 0 0 unless $ct =~ m[<select name="fromAccountID">(.+?)</select>]is
165 0 0 if (not $account or $_ eq $account)
189 0 0 unless $mech->content =~ />Informasi Saldo(?:<[^>]+>\s*)*:\s*(?:<[^>]+>\s*)*(?:Rp\.)&nbsp;([0-9.]+),(\d+)\s*</s
214 0 0 unless ($start_date)
215 0 0 if (defined $args{'days'}) { }
249 0 0 if $mech->content =~ />Keterangan Transaksi</
250 0 0 if $mech->content =~ m[<font class="alert">(.+)</font>]
257 0 0 if not $resp or $resp->[0] != 200
263 3 4 if ($page =~ /(?:^|"header">)(HISTORI TRANSAKSI|MUTASI REKENING)/m) { }
1 3 elsif ($page =~ /^CMS-Mandiri/ms) { }
1 2 elsif ($page =~ /$re_mcm_v201901/mx) { }
1 1 elsif ($page =~ /$re_mcm_v201103/mx) { }
1 0 elsif ($page =~ /$re_mcm_v201107/mx) { }
292 3 4 if ($self->_variant eq 'ib') { }
1 3 elsif ($self->_variant eq 'cms') { }
3 0 elsif ($self->_variant =~ /^mcm/) { }
308 0 3 unless ($page =~ /Tampilkan Berdasarkan(?:\s+|(?:<[^>]+>\s*)*):(?:\s+|(?:<[^>]+>\s*)*)Tanggal(?:\s+|(?:<[^>]+>\s*)*)Urutkan Berdasarkan(?:\s+|(?:<[^>]+>\s*)*):(?:\s+|(?:<[^>]+>\s*)*)Mulai dari yang kecil/s)
314 0 3 unless ($page =~ /(?:^|>)Nomor Rekening(?:\s+|(?:<[^>]+>\s*)*):(?:\s+|(?:<[^>]+>\s*)*)(\d+) (Rp\.|[A-Z]+)/m)
318 3 0 $2 eq 'Rp.' ? :
320 0 3 $page =~ />Tidak ditemukan catatan</ ? :
323 0 3 unless ($empty_stmt or $page =~ /(?:|>)Saldo Akhir(?:\s+|(?:<[^>]+>\s*)*):(?:\s+|(?:<[^>]+>\s*)*)\d/m)
338 0 3 unless ($page =~ /(?:^|>)Periode Transaksi(?:\s+|(?:<[^>]+>\s*)*):(?:\s+|(?:<[^>]+>\s*)*)(\d\d?) ($shortmon_re) (\d\d\d\d)\s*-\s*(\d\d?) ($shortmon_re) (\d\d\d\d)/m)
341 0 3 unless $shortmon{$2}
342 0 3 unless $shortmon{$5}
348 0 3 if ('DateTime'->compare($stmt->{'start_date'}, $today) == 1)
351 0 3 if ('DateTime'->compare($stmt->{'end_date'}, $today) == 1)
355 0 3 if ($empty_stmt) { }
359 0 3 unless ($page =~ /(?:^|>)Total Kredit(?:\s+|(?:<[^>]+>\s*)*):(?:\s+|(?:<[^>]+>\s*)*)([0-9,.]+)[.,](\d\d)/m)
364 0 3 unless ($page =~ /(?:^|>)Total Debet(?:\s+|(?:<[^>]+>\s*)*):(?:\s+|(?:<[^>]+>\s*)*)([0-9,.]+)[.,](\d\d)/m)
378 0 1 unless ($page =~ /^- End Of Statement -/m)
382 0 1 unless ($page =~ /^Account No\s*:\s*(\d+)/m)
387 0 1 unless ($page =~ /^Account Name\s*:\s*(.+?)[\012\015]/m)
392 0 1 unless ($page =~ /^Currency\s*:\s*([A-Z]+)/m)
399 0 1 unless ($page =~ m[Period\s*:\s*(\d\d?)/(\d\d?)/(\d\d\d\d)\s*-\s*(\d\d?)/(\d\d?)/(\d\d\d\d)]m)
407 0 1 if ('DateTime'->compare($stmt->{'start_date'}, $today) == 1)
410 0 1 if ('DateTime'->compare($stmt->{'end_date'}, $today) == 1)
428 0 3 unless $page =~ /$re_tx/mx
433 1 2 $+{'date_y'} < 100 ? :
438 0 3 unless $page =~ /.*$re_tx/s
440 1 2 $+{'date_y'} < 100 ? :
451 3 4 if ($self->_variant eq 'ib') { }
1 3 elsif ($self->_variant eq 'cms') { }
3 0 elsif ($self->_variant =~ /^mcm/) { }
470 0 3 if $page =~ />Tidak ditemukan catatan</
477 1 2 unless (@e)
503 3 3 if ($db == 0) { }
3 0 elsif ($cr == 0) { }
507 3 3 if (not $last_date or 'DateTime'->compare($last_date, $tx->{'date'})) { }
519 0 6 if ($seq > 1 and $tx->{'description'} =~ /^Reversal \(Error Correction\)/ and $tx->{'amount'} == -$tx[-1]{'amount'}) { }
540 0 1 if ($page =~ /<br|<p/i)
563 2 1 $e->{'montx'} < $stmt->{'start_date'}->mon || $e->{'montx'} == $stmt->{'start_date'}->mon && $e->{'daytx'} == $stmt->{'start_date'}->day ? :
570 1 2 $e->{'monbk'} < $stmt->{'start_date'}->mon || $e->{'monbk'} == $stmt->{'start_date'}->mon && $e->{'daybk'} == $stmt->{'start_date'}->day ? :
573 2 1 $e->{'amtc'} eq 'C' ? :
574 0 3 $e->{'balc'} eq 'C' ? :
577 2 1 if (not $last_date or 'DateTime'->compare($last_date, $tx->{'date'})) { }
598 1 2 $self->_variant =~ /^mcm-v201901/ ? :
599 1 2 $self->_variant =~ /^mcm-v201901/ ? :
605 1 13 if $skip_header and $i == 1
606 0 13 unless /\S/
607 0 13 unless /$re_tx/mx
618 5 8 $+{'date_y'} < 100 ? :
619 5 8 if defined $+{'desc3'}
620 9 4 if ($+{'amount_cr'}) { }
623 5 4 if ($num_formatted) { }
630 6 3 $cr ? :
632 2 2 $+{'amount_dbmarker'} ? :
634 8 5 if (defined $+{'bal'})
635 0 8 $+{'bal_dbmarker'} ? :
647 0 13 unless $row->{'account'} eq $stmt->{'account'}
649 0 13 unless $row->{'currency'} eq $stmt->{'currency'}
658 7 6 $row->{'desc2'} ? :
1 12 $row->{'desc3'} ? :
662 5 8 if (not $last_date or 'DateTime'->compare($last_date, $tx->{'date'})) { }