Branch Coverage

blib/lib/Lab/Instrument/Keithley2400.pm
Criterion Covered Total %
branch 0 318 0.0


line true false branch
74 0 0 unless (defined $value)
78 0 0 if ($self->device_settings->{'gate_protect'})
79 0 0 if ($self->get_output == 1 and $value == 0) { }
0 0 elsif ($self->get_output == 0 and $value == 1) { }
90 0 0 if ($value == 1) { }
0 0 elsif ($value == 0) { }
93 0 0 if (defined $current_level)
114 0 0 unless (defined $read_mode and $read_mode =~ /device|cache/u)
118 0 0 if ($read_mode eq "cache" and defined $self->{'device_cache'}{'output'})
130 0 0 if (not defined $offstate) { }
0 0 elsif ($offstate =~ /\b(HIMPEDANCE|HIMP|himpedance|himp|NORMAL|NORM|normal|norm|ZERO|zero|GUARD|GUAR|guard|guar)\b/u) { }
153 0 0 if ($terminals =~ /\b(FRONT|FRON|front|fron|REAR|rear)\b/u) { }
168 0 0 if ($value =~ /\b(ON|on|1|OFF|off|0)\b/u) { }
184 0 0 unless (defined $list)
192 0 0 if ((my $length = @list) > 1 or $list =~ /\b(ALL|all)\b/u) { }
201 0 0 if ($onfunction =~ /\b(CURRENT|CURR|current|curr|VOLTAGE|VOLT|voltage|volt)\b/u) { }
0 0 elsif ($onfunction =~ /\b(RESISTANCE|RES|resistance|res)\b/u) { }
0 0 elsif ($onfunction =~ /\b(ALL|all)\b/u) { }
0 0 elsif ($onfunction =~ /\b(OFF|off|NONE|none)\b/u) { }
238 0 0 if ($onfunction =~ /(VOLTAGE|VOLT|voltage|volt|CURRENT|CURR|current|curr|RESISTANCE|RES|resistance|res)/u) { }
256 0 0 if ($mode =~ /\b(AUTO|auto|MAN|man)\b/u) { }
270 0 0 if ($zerocompensation =~ /\b(ON|on|1|OFF|off|0)\b/u) { }
288 0 0 if ($function =~ /\b(CURRENT|CURR|current|curr)\b/u) { }
0 0 elsif ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u) { }
0 0 elsif ($function =~ /\b(RESISTANCE|RES|resistance|res)\b/u) { }
289 0 0 if ($range =~ /\b(AUTO|auto|UP|up|DOWN|down|MIN|min|MAX|max|DEF|def)\b/u) { }
0 0 elsif ($range >= -1.05 and $range <= 1.05) { }
305 0 0 if ($range =~ /\b(AUTO|auto|UP|up|DOWN|down|MIN|min|MAX|max|DEF|def)\b/u) { }
0 0 elsif ($range >= -210 and $range <= 210) { }
321 0 0 if ($range =~ /\b(AUTO|auto|UP|up|DOWN|down|MIN|min|MAX|max|DEF|def)\b/u) { }
0 0 elsif ($range >= 0 and $range <= 210000000) { }
344 0 0 if ($range =~ /\b(AUTO|auto)\b/u) { }
345 0 0 if (defined $llimit and defined $ulimit and $llimit <= $ulimit) { }
364 0 0 if ($range > $self->set_complience($function))
382 0 0 if (not defined $function || defined $complience) { }
0 0 elsif (not defined $complience and $function =~ /\b\d+(e\d+|E\d+|exp\d+|EXP\d+)?\b/u or $function =~ /\b(MIN|min|MAX|max|DEF|def|AUTO|auto)\b/u) { }
0 0 elsif (not defined $complience) { }
398 0 0 unless (defined $function)
402 0 0 if ($function =~ /\b(CURRENT|CURR|current|curr)\b/u) { }
0 0 elsif ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u) { }
403 0 0 if ($complience < -210 or $complience > 210)
411 0 0 if ($complience < "-1.05" or $complience > "1.05")
425 0 0 if ($function =~ /\b(CURRENT|CURR|current|curr)\b/u) { }
0 0 elsif ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u) { }
447 0 0 unless (defined $nplc)
448 0 0 if (not defined $function) { }
0 0 elsif ($function =~ /\b(CURRENT|CURR|current|curr|VOLTAGE|VOLT|voltage|volt|RESISTANCE|RES|resistance|res)\b/u) { }
0 0 elsif ($function >= 0.01 and $function <= 1000 or $function =~ /\b(MAX|max|MIN|min|DEF|def)\b/u) { }
476 0 0 if ($nplc < "0.01" and $nplc > 1000 and not $nplc =~ /\b(MAX|max|MIN|min|DEF|def)\b/u)
483 0 0 if ($function =~ /\b(CURRENT|CURR|current|curr|VOLTAGE|VOLT|voltage|volt|RESISTANCE|RES|resistance|res)\b/u) { }
486 0 0 if ($nplc > 10) { }
495 0 0 if ($nplc =~ /\b(MAX|max|MIN|min|DEF|def)\b/u) { }
0 0 elsif ($nplc =~ /\b\d+(e\d+|E\d+|exp\d+|EXP\d+)?\b/u) { }
522 0 0 if (not defined $function) { }
0 0 elsif ($function =~ /\b(CURRENT|CURR|current|curr|VOLTAGE|VOLT|voltage|volt|RESISTANCE|RES|resistance|res)\b/u) { }
544 0 0 unless (defined $count or defined $filter)
548 0 0 if ($count >= 1 and $count <= 100) { }
0 0 elsif ($count =~ /\b(OFF|off|0)\b/u) { }
549 0 0 if (defined $filter and $filter =~ /\b(REPEAT|REP|repeat|rep|MOVING|MOV|moving|mov)\b/u) { }
0 0 elsif (not defined $filter) { }
592 0 0 if ($mode =~ /\b(ON|on|1|OFF|off|0)\b/u) { }
0 0 elsif (not defined $mode) { }
611 0 0 if ($function =~ /\b(CURRENT|CURR|current|curr)\b/u or $function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u) { }
613 0 0 if ($mode =~ /\b(FIXED|FIX|fixed|fix)\b/u or $mode =~ /\b(LIST|list)\b/u or $mode =~ /\b(SWEEP|SWE|sweep|swe)\b/u) { }
641 0 0 if (not defined $function || defined $range) { }
0 0 elsif (not defined $range and $function =~ /\b\d+(e\d+|E\d+|exp\d+|EXP\d+)?\b/u or $function =~ /\b(MIN|min|MAX|max|DEF|def|AUTO|auto)\b/u) { }
652 0 0 if ($function =~ /\b(CURRENT|CURR|current|curr)\b/u) { }
0 0 elsif ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u) { }
653 0 0 if ($range >= -1.05 and $range <= 1.05 or $range eq 'AUTO') { }
664 0 0 if ($range >= -210 and $range <= 210 or $range eq 'AUTO') { }
681 0 0 if ($range =~ /\b(AUTO|auto)\b/u) { }
0 0 elsif ($range =~ /\b(MIN|min|MAX|max|DEF|def)\b/u) { }
704 0 0 if (not defined $value || defined $function) { }
0 0 elsif (not defined $value and $function =~ /\b(CURRENT|CURR|current|curr)\b/u || $function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u) { }
0 0 elsif (not defined $value and $function >= -210 and $function <= 210) { }
713 0 0 if ($triggerstatus =~ /\b(IMMEDIATE|IMM|immediate|imm)\b/u) { }
727 0 0 if ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u and $value >= -210 and $value <= 210 or $function =~ /\b(CURRENT|CURR|current|curr)\b/u and $value >= -1.05 and $value <= 1.05) { }
738 0 0 if ($value <= $self->set_source_range($function))
746 0 0 if ($triggerstatus =~ /\b(IMMEDIATE|IMM|immediate|imm)\b/u) { }
747 0 0 if ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u) { }
748 0 0 if ($self->get_output('STATE') =~ /\b(OFF|off)\b/u) { }
779 0 0 if (not defined $limit) { }
0 0 elsif ($limit >= -210 and $limit <= 210) { }
0 0 elsif ($limit =~ /\b(NONE|none|MIN|min|MAX|max|DEF|def)\b/u) { }
808 0 0 unless (defined $delay)
813 0 0 if ($delay >= 0 and $delay <= 999.9999) { }
0 0 elsif ($delay =~ /\b(MIN|min|MAX|max|DEF|def)\b/u) { }
0 0 elsif ($delay =~ /\b(AUTO|auto)\b/u) { }
845 0 0 if ($self->set_sense_onfunction =~ /\b(RESISTANCE|RES|resistance|res)\b/u)
851 0 0 $function =~ /\b(CURRENT|CURR|current|curr)\b/u ? :
855 0 0 if (defined $complience)
858 0 0 if (defined $sense)
871 0 0 if ($function =~ /\b(CURRENT|CURR|current|curr)\b/u or $function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u) { }
892 0 0 if ($function eq 'CURR') { }
0 0 elsif ($function eq 'VOLT') { }
902 0 0 unless (defined $function)
913 0 0 unless (defined $function)
939 0 0 unless (defined $function)
943 0 0 unless ($self->get_output)
954 0 0 if (defined $time and defined $rate) { }
0 0 elsif (defined $rate and not defined $time) { }
961 0 0 if ($target == $start)
970 0 0 if ($points > $points_max)
1000 0 0 unless ($self->{'armed'})
1011 0 0 unless (defined $timeout)
1031 0 0 unless (defined $timeout)
1036 0 0 if ($self->query(':STATUS:OPERATION:CONDITION?', {'timeout', 100}) >= 1024) { }
1084 0 0 if (not defined $function) { }
0 0 elsif ($function =~ /\b(CURRENT|current|CURR|curr|VOLTAGE|voltage|VOLT|volt|RESISTANCE|resistance|RES|res)\b/u) { }
1110 0 0 unless (defined $range)
1116 0 0 if ($function =~ /\b(RESISTANCE|RES|resistance|res)\b/u)
1121 0 0 if ($function eq $self->set_source_mode) { }
0 0 elsif ($function =~ /\b(ALL|all)\b/u) { }
1128 0 0 if ($range <= $self->set_complience) { }
1137 0 0 if ($nplc < "0.01")
1161 0 0 if ($time >= 2) { }
1179 0 0 if ($start != $self->_set_source_amplitude)
1214 0 0 unless (defined $spacing)
1217 0 0 unless (defined $ranging)
1220 0 0 unless (defined $nplc)
1223 0 0 unless (defined $nop)
1235 0 0 if ($start != $self->_set_source_amplitude)
1267 0 0 unless (defined $spacing)
1270 0 0 unless (defined $ranging)
1273 0 0 unless (defined $nplc)
1276 0 0 unless (defined $nop)
1288 0 0 if ($start != $self->_set_source_amplitude)
1329 0 0 if ($ranging =~ /\b(BEST|best|FIXED|FIX|fixed|fix|AUTO|auto)\b/u) { }
1348 0 0 if ($spacing =~ /\b(LINEAR|LIN|linear|lin|LOGARITHMIC|LOG|logarithmic|log)\b/u) { }
1369 0 0 if (not defined $start and $function >= -210 and $function <= 210) { }
1380 0 0 if ($function =~ /\b(CURRENT|CURR|current|curr)\b/u and $start < -1.05 || $start > 1.05) { }
0 0 elsif ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u and $start < -210 || $start > 210) { }
0 0 elsif ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u or $function =~ /\b(CURRENT|CURR|current|curr)\b/u) { }
1415 0 0 if (not defined $stop and $function >= -210 and $function <= 210) { }
1426 0 0 if ($function =~ /\b(CURRENT|CURR|current|curr)\b/u and $stop < -1.05 || $stop > 1.05) { }
0 0 elsif ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u and $stop < -210 || $stop > 210) { }
0 0 elsif ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u or $function =~ /\b(CURRENT|CURR|current|curr)\b/u) { }
1461 0 0 if (not defined $step and $function >= -420 and $function <= 420) { }
1472 0 0 if ($function =~ /\b(CURRENT|CURR|current|curr)\b/u and $step < -2.1 || $step > 2.1) { }
0 0 elsif ($function =~ /\b(VOLTAGE|VOLT|voltage|volt)\b/u and $step < -420 || $step > 420) { }
1494 0 0 if (int(($stop - $start) / $step) != ($stop - $start) / $step)
1509 0 0 if ($nop >= 1 and $nop <= 2500) { }
1536 0 0 if ($function eq 'NONE') { }
1553 0 0 if ($nop >= 2 and $nop <= 2500) { }
1586 0 0 if ($status != $Lab::VISA::VI_SUCCESS)
1602 0 0 if ($status != $Lab::VISA::VI_SUCCESS)
1608 0 0 if ($num_of_onfunctions > 1)
1617 0 0 if ($print eq "PRINT")
1629 0 0 if ($print eq "PRINT")
1644 0 0 if ($triggercount >= 1 and $triggercount <= 2500) { }
1659 0 0 unless (defined $triggerdelay)
1664 0 0 if ($triggerdelay >= 0 and $triggerdelay <= 999999.999) { }
0 0 elsif ($triggerdelay =~ /\b(MIN|min|MAX|max|DEF|def)\b/u) { }
1685 0 0 if ($timer >= 0 and $timer <= 999999.999) { }
1712 0 0 if (not defined $data) { }
0 0 elsif ($data =~ /\b(ON|on)\b/u) { }
0 0 elsif ($data =~ /\b(OFF|off)\b/u) { }
0 0 elsif ($data =~ /\b(CLEAR|clear)\b/u) { }
1733 0 0 if ($text) { }