Branch Coverage

lib/Finance/IG.pm
Criterion Covered Total %
branch 1 300 0.3


line true false branch
128 0 1 if (eval 'require Term::Chrome') { }
193 0 0 if $self->isdemo
235 0 0 if $code != 200
263 0 0 if ref $hash ne 'ARRAY'
264 0 0 if ref $toflatten ne 'ARRAY'
270 0 0 if (exists $h->{$key})
272 0 0 if (defined $h->{$key})
274 0 0 if ref $h->{$key} ne 'HASH'
277 0 0 if exists $h->{$subkey}
299 0 0 if (ref $to eq 'Time::Piece')
303 0 0 if (ref $from eq 'Time::Piece')
307 0 0 unless $to =~ /^[-0-9T:]*$/
308 0 0 unless $from =~ /^[-0-9T:]*$/
324 0 0 if $from
325 0 0 if $to
327 0 0 if $pageNumber
328 0 0 if $pageSize
330 0 0 $_ ? :
332 0 0 if $url
341 0 0 if ($code == 200) { }
350 0 0 if $rpage > $resp->{'metadata'}{'pageData'}{'pageNumber'}
386 0 0 if (ref $to eq 'Time::Piece')
390 0 0 if (ref $from eq 'Time::Piece')
395 0 0 unless $to =~ /^[-0-9T:]*$/
396 0 0 unless $from =~ /^[-0-9T:]*$/
411 0 0 if $from ne ''
412 0 0 if $to ne ''
413 0 0 if ($detailed) { }
422 0 0 if $pageNumber
424 0 0 if $pageSize
429 0 0 $_ ? :
431 0 0 if $url
444 0 0 if ($code == 200) { }
448 0 0 if @activities == 0
862 0 0 if $position->{'direction'} eq 'SELL'
866 0 0 unless $position->{'held'} = 'Time::Piece'->strptime($position->{'createdDateUTC'}, '%Y-%m-%dT%H:%M:%S')
893 0 0 unless $h = 'Time::Piece'->strptime($subtotal->{'createdDateUTC'}, '%Y-%m-%dT%H:%M:%S')
905 0 0 if $subtotal->{'stopLevel'}
913 0 0 if @$total > 1
918 0 0 if $position->{'level'} > 0
927 0 0 $_ ? :
996 0 0 if $position->{'direction'} eq 'SELL'
1006 0 0 unless $position->{'held'} = 'Time::Piece'->strptime($position->{'createdDateUTC'}, '%Y-%m-%dT%H:%M:%S')
1010 0 0 if $position->{'held'} > 0
1056 0 0 if $key =~ s/^-//
1058 0 0 unless exists $Finance::IG::a->{$key} and exists $Finance::IG::b->{$key}
1065 0 0 if ($x1 eq $x1 + 0 and $x2 eq $x2 + 0) { }
1074 0 0 if $result
1162 0 0 if ($ms ne 'TRADEABLE')
1186 0 0 if ($code == 200) { }
1191 0 0 if (defined $dealReference and length $dealReference > 5)
1205 0 0 if $done
1206 0 0 if $notdone
1305 0 0 if (exists $existhash{$epic})
1315 0 0 if ($wantedsize <= 0)
1322 0 0 if ($ms ne 'TRADEABLE' and not $ignoretradeable)
1346 0 0 if ($code == 200)
1352 0 0 if (defined $dealReference and length $dealReference > 5)
1361 0 0 if $done
1362 0 0 if $notdone
1437 0 0 if (ref $to eq 'Time::Piece')
1441 0 0 if (ref $from eq 'Time::Piece')
1463 0 0 if $resolution eq '1d'
1464 0 0 if $resolution eq '1h'
1465 0 0 if $resolution eq '1h'
1466 0 0 if $resolution eq '2h'
1467 0 0 if $resolution eq '3h'
1468 0 0 if $resolution eq '1m'
1469 0 0 if $resolution eq '2m'
1470 0 0 if $resolution eq '3m'
1471 0 0 if $resolution eq '5m'
1472 0 0 if $resolution eq '10m'
1473 0 0 if $resolution eq '15m'
1474 0 0 if $resolution eq '30m'
1475 0 0 if $resolution eq '1s'
1476 0 0 if $resolution eq '1w'
1477 0 0 if $resolution eq '1M'
1480 0 0 if defined $resolution and 0 == grep({$resolution eq $_;} 'DAY', 'HOUR', 'HOUR_2', 'HOUR_3', 'HOUR_4', 'MINUTE', 'MINUTE_10', 'MINUTE_15', 'MINUTE_2', 'MINUTE_3', 'MINUTE_30', 'MINUTE_5', 'MONTH', 'SECOND', 'WEEK')
1503 0 0 if $url
1584 0 0 if $fudebug
1587 0 0 if $fudebug
1588 0 0 if ref $item eq ''
1589 0 0 if (ref $item eq 'HASH')
1591 0 0 if $fudebug
1594 0 0 if $fudebug
1595 0 0 if (ref $item->{$key} eq 'HASH')
1599 0 0 if $fudebug
1601 0 0 if $fudebug
1604 0 0 if (ref $item->{$key}{$key2} eq 'HASH')
1608 0 0 if $fudebug
1610 0 0 if $fudebug
1612 0 0 if $fudebug
1617 0 0 if $fudebug
1620 0 0 if (ref $item->{$key} eq 'ARRAY')
1622 0 0 if $fudebug
1630 0 0 if (ref $item eq 'ARRAY')
1632 0 0 if $fudebug
1639 0 0 if $fudebug
1673 0 0 if ref $position ne 'HASH'
1674 0 0 unless defined $item
1678 0 0 if (exists $position->{$item}) { }
0 0 elsif (exists $p->{$item}) { }
0 0 elsif (exists $m->{$item}) { }
1748 0 0 if $code != 200
1757 0 0 if @wantedmarkets == 0
1758 0 0 if @wantedmarkets != 1
1808 0 0 unless open F, $f
1818 0 0 if (/\|/) { }
0 0 elsif (/^Name/) { }
0 0 elsif (/^Total/) { }
1851 0 0 if ($writenewfile)
1854 0 0 unless (-e $f)
1856 0 0 unless open my $g, '>', $f
1902 0 0 unless open F, $f
1913 0 0 if (/^Total/) { }
0 0 elsif (/ Positions$/) { }
0 0 elsif (/^ *$/) { }
0 0 elsif (/#/) { }
0 0 elsif (not /\|/) { }
0 0 elsif (/Epic/) { }
1943 0 0 unless defined $names[0]
2020 0 0 if $out eq 'stdout'
2022 0 0 if defined $up and ref $up eq '' and not defined $down
2024 0 0 if (defined $up and ref $up ne 'CODE')
2032 0 0 if defined $up and $v1 > $up
2033 0 0 if defined $down and $v1 < $down
2034 0 0 if defined $up and $v1 > $up * 5
2035 0 0 if defined $down and $v1 < 5 * $down
2039 0 0 if defined $up and ref $up eq 'CODE'
2040 0 0 unless defined $up
2044 0 0 if (ref $position eq 'ARRAY')
2052 0 0 if abs $2 > abs $x
2071 0 0 if $self->col and defined $INC{'Term/Chrome.pm'}
2074 0 0 if $self->col and defined $INC{'Term/Chrome.pm'}
2079 0 0 if (not defined $position or $position eq '')
2096 0 0 if $2 > $x
2104 0 0 if $self->col and defined $INC{'Term/Chrome.pm'}
2106 0 0 if $self->col and defined $INC{'Term/Chrome.pm'}
2138 0 0 if $len
2139 0 0 if (defined $item and $item ne '' and exists $position->{$item} and defined $position->{$item}) { }
0 0 elsif (defined $self->fetch($position, $item)) { }
2144 0 0 if ($item eq 'dbid' and exists $INC{'Term/Chrome.pm'} and $self->col)
2162 0 0 if ($item eq 'dbid' and defined $INC{'Term/Chrome.pm'} and $self->col)
2190 0 0 if ($len ne '')
2193 0 0 if $len ne ''
2194 0 0 if $len and $len < length $s and $len >= 1
2200 0 0 if $self->col and defined $INC{'Term/Chrome.pm'}
2205 0 0 if (ref $col ne '')
2236 0 0 if @dates == 0
2237 0 0 if @dates == 1