Branch Coverage

blib/lib/VIC/PIC/Functions/ADC.pm
Criterion Covered Total %
branch 15 36 41.6


line true false branch
12 0 3 unless $self->doesroles("GPIO", "ADC", "Chip", "CodeGen")
13 0 3 unless (defined $self->adc_channels and $self->adc_channels > 0)
17 0 3 unless (exists $self->registers->{'ADCON0'} and exists $self->registers->{'ADCON1'})
22 3 0 if (@_)
25 3 0 if $clock > 0
26 0 3 unless $clock
27 0 3 if $scale < 2
29 0 3 if $self->code_config->{'adc'}{'internal'}
36 3 0 if (defined $channel)
38 3 0 defined $self->code_config->{'adc'}{'right_justify'} ? :
59 0 0 unless $self->doesroles("ADC")
60 0 0 unless (defined $self->adc_channels and $self->adc_channels > 0)
64 0 0 unless (exists $self->registers->{'ADCON0'})
77 0 3 unless $self->doesroles("ADC", "GPIO", "Chip")
78 0 3 unless (defined $self->adc_channels and $self->adc_channels > 0)
83 0 3 if defined $varlow
84 0 3 unless (exists $self->registers->{'ADCON0'} and exists $self->registers->{'ADRESH'} and exists $self->registers->{'ADRESL'})
103 0 3 if defined $varlow