Condition Coverage

blib/lib/Excel/Writer/XLSX/Worksheet.pm
Criterion Covered Total %
condition 577 697 82.7


and 3 conditions

line !l l&&!r l&&r condition
615 27 167 6 $data[2] and $data[4]
699 7 0 1 $row_first == $row_last and $col_first == $col_last
1224 0 0 9 $row1 == 0 and $col1 == 0
0 7 2 $row1 == 0 and $col1 == 0 and $row2 == $self->{'_xls_rowmax'} - 1
7 1 1 $row1 == 0 and $col1 == 0 and $row2 == $self->{'_xls_rowmax'} - 1 and $col2 == $self->{'_xls_colmax'} - 1
1319 6 13 6 @tokens == 2 and $tokens[0] == 2
13 2 4 @tokens == 5 and $tokens[0] == 2
15 1 3 @tokens == 5 and $tokens[0] == 2 and $tokens[2] == 1
3 0 3 @tokens == 5 and $tokens[0] == 2 and $tokens[2] == 1 and $tokens[3] == 2
1516 2 2 0 $token ne 'items' and $token ne '%'
1536 59 0 0 not $operator and $tokens[0]
1546 5 2 0 $operator != 2 and $operator != 5
1575 36 20 3 $operator == 2 and $token =~ /[*?]/
1612 1 38 1 $row_num_1 == 0 and $row_num_2 == $self->{'_xls_rowmax'} - 1
2 36 1 $col_num_1 == 0 and $col_num_2 == $self->{'_xls_colmax'} - 1
1628 37 2 1 $range1 eq $range2 and not $row_col_only
2003 9807 0 0 $self->{'_leading_zeros'} and $token =~ /^0\d+$/
2224 7615 3 2 $self->{'_optimization'} == 1 and $row > $self->{'_previous_row'}
2286 2700 14 280 $self->{'_optimization'} == 1 and $row > $self->{'_previous_row'}
2380 28 4 1 $last eq 'format' and $pos > 0
2435 20 0 8 $self->{'_optimization'} == 1 and $row > $self->{'_previous_row'}
2485 60 1 0 $self->{'_optimization'} == 1 and $row > $self->{'_previous_row'}
2538 110 1 0 $self->{'_optimization'} == 1 and $row > $self->{'_previous_row'}
2591 4 0 4 $row1 == $row2 and $col1 == $col2
2607 8 0 0 $self->{'_optimization'} == 1 and $row > $self->{'_previous_row'}
2619 8 0 8 $row == $row1 and $col == $col1
2657 4 0 0 $self->{'_optimization'} == 1 and $row > $self->{'_previous_row'}
2747 53 17 13 defined $args[3] and not ref $args[3]
2805 66 5 4 $url_str and not $external
2841 81 1 0 $self->{'_optimization'} == 1 and $row > $self->{'_previous_row'}
2907 129 0 0 $self->{'_optimization'} == 1 and $row > $self->{'_previous_row'}
3031 427 166 58 $year % 4 == 0 and $year % 100
3051 206 4 423 $date_1904 == 0 and $days > 59
3166 9 15 0 $row_first == $row_last and $col_first == $col_last
3189 22 26 20 $row == $row_first and $col == $col_first
3238 0 7 0 $row_first == $row_last and $col_first == $col_last
3287 0 7 7 $row == $row_first and $col == $col_first
3322 5 63 0 @_ != 5 and @_ != 3
3413 65 2 1 $param->{'validate'} eq 'none' and not defined $param->{'input_message'}
67 0 1 $param->{'validate'} eq 'none' and not defined $param->{'input_message'} and not defined $param->{'input_title'}
3521 49 17 1 $param->{'input_title'} and length $param->{'input_title'} > 32
3528 62 4 0 $param->{'error_title'} and length $param->{'error_title'} > 32
3535 50 15 1 $param->{'input_message'} and length $param->{'input_message'} > 255
3542 62 3 0 $param->{'error_message'} and length $param->{'error_message'} > 255
3764 79 17 53 defined $param->{'criteria'} and exists $criteria_type{lc $param->{'criteria'}}
3774 1 0 1 defined $param->{'value'} and $param->{'value'} =~ /T/
3787 1 0 1 defined $param->{'minimum'} and $param->{'minimum'} =~ /T/
3800 1 0 1 defined $param->{'maximum'} and $param->{'maximum'} =~ /T/
3884 61 14 74 $row1 == $row2 and $col1 == $col2
3899 122 0 27 defined $param->{'format'} and ref $param->{'format'}
4136 5 0 20 $param->{'min_type'} eq 'min' and $param->{'min_value'} == 0
4140 4 0 21 $param->{'max_type'} eq 'max' and $param->{'max_value'} == 0
4220 4 6 4 $type ne 'percent' and $type ne 'percentile'
10 2 2 $type ne 'percent' and $type ne 'percentile' and $type ne 'number'
8 2 0 $type ne 'percent' and $type ne 'percentile' and $type ne 'number' and $type ne 'formula'
4238 16 7 7 defined $user_props->[$i]{'criteria'} and $user_props->[$i]{'criteria'} eq '>'
4274 0 0 48 @_ and $_[0] =~ /^\D/
4502 74 0 9 defined $user_data->{'format'} and ref $user_data->{'format'}
4628 49 8 1 $type ne 'line' and $type ne 'column'
57 1 0 $type ne 'line' and $type ne 'column' and $type ne 'win_loss'
4715 57 0 1 $date_range and not $date_range =~ /!/
5051 928 15338 318 not $ignore_row || $ignore_col and $self->{'_optimization'} == 1
5152 4747 1 8 $x1 < 0 and $col_start > 0
5158 4747 1 4 $y1 < 0 and $row_start > 0
5358 154 5 16 $hidden == 1 and $anchor != 4
5397 49 15 8 $hidden == 1 and $anchor != 4
5541 388 10 0 $chart->{'_combined'} and $chart->{'_combined'}{'_already_inserted'}
5866 0 1 22 $target and not exists $self->{'_drawing_rels'}{$url}
5962 28 17 45 not $used and $id != 0
6097 0 0 12 $shape->{'_start'} and $shape->{'_end'}
6100 0 0 12 $shape->{'_start_side'} and $shape->{'_end_side'}
6170 2 2 1 $smidx < $emidx and $smidy > $emidy
6171 3 1 1 $smidx > $emidx and $smidy < $emidy
6679 1 4 0 @pairs and $pairs[-2] eq 'result'
6812 779 0 9 not defined $self->{'_dim_rowmin'} and defined $self->{'_dim_colmin'}
624 20 135 $self->{'_dim_rowmin'} == $self->{'_dim_rowmax'} and $self->{'_dim_colmin'} == $self->{'_dim_colmax'}
7531 9044 1076 0 $self->{'_set_rows'}{$row} and $self->{'_set_rows'}{$row}[1]
7565 294 0 8 $string =~ /^/ and $string =~ m[$]
7589 32 26 17 $value and not $value =~ /^([+-]?)(?=\d|\.\d)\d*(\.\d*)?([Ee]([+-]?\d+))?$/
7783 17 3 3 $self->{'_fit_page'} and $self->{'_fit_width'} != 1
7787 17 2 4 $self->{'_fit_page'} and $self->{'_fit_height'} != 1
8180 8 8 2 @filters == 1 and @non_blanks == 0
8334 0 1 81 $self->{'_table'} and $self->{'_table'}{$row_num}
1 0 81 $self->{'_table'} and $self->{'_table'}{$row_num} and $self->{'_table'}{$row_num}{$col_num}
8496 7 8 13 $row and $col
8579 7 5 26 $top_row == $row and $left_col == $col
8593 14 14 10 $row and $col
8876 0 0 56 $format->{'_font'} eq 'Calibri' and not $format->{'_hyperlink'}
9016 3 0 65 $row_first == $row_last and $col_first == $col_last
9190 31 0 5 defined $param->{'minimum'} and defined $param->{'maximum'}
9228 2 0 2 defined $param->{'criteria'} and $param->{'criteria'} eq '%'
9330 33 0 4 exists $param->{'icons_only'} and $param->{'icons_only'}
9334 31 0 6 exists $param->{'reverse_icons'} and $param->{'reverse_icons'}

or 2 conditions

line l !l condition
67 10 1363 $_[9] || 0
71 976 397 $_[13] || 2079
491 6 21 shift() || ''
492 25 2 shift() || {}
641 17 181 $data[4] || 0
738 44 22 shift() || 0
741 41 25 shift() || 0
859 30 1 $_[0] || ''
860 2 29 $_[1] || 0.3
861 23 8 $_[2] || {}
924 14 1 $_[0] || ''
925 2 13 $_[1] || 0.3
926 7 8 $_[2] || {}
1764 3 0 $_[0] || 100
1785 3 0 $_[0] || 100
1938 0 0 $_[0] || 0
1939 0 0 $_[1] || 0
2681 1 0 $_[3] || 0
2820 17 66 $url_str || ''
2975 205 1 $4 || 0
3069 277 105 shift() || 0
3070 53 329 shift() || 0
3071 4 378 shift() || 0
3124 3 3 shift() || 0
4042 0 1 $param->{'min_type'} ||= 'min'
4043 0 1 $param->{'max_type'} ||= 'max'
4044 0 1 $param->{'min_value'} ||= 0
4045 0 1 $param->{'max_value'} ||= 0
4046 0 1 $param->{'min_color'} ||= '#FF7128'
4047 0 1 $param->{'max_color'} ||= '#FFEF9C'
4061 1 3 $param->{'min_type'} ||= 'min'
4062 1 3 $param->{'mid_type'} ||= 'percentile'
4063 1 3 $param->{'max_type'} ||= 'max'
4064 1 3 $param->{'min_value'} ||= 0
4066 1 3 $param->{'max_value'} ||= 0
4067 1 3 $param->{'min_color'} ||= '#F8696B'
4068 1 3 $param->{'mid_color'} ||= '#FFEB84'
4069 1 3 $param->{'max_color'} ||= '#63BE7B'
4099 4 25 $param->{'min_value'} ||= 0
4100 4 25 $param->{'max_value'} ||= 0
4101 15 14 $param->{'bar_color'} ||= '#638EC6'
4103 2 27 $param->{'bar_only'} ||= 0
4104 1 28 $param->{'bar_no_border'} ||= 0
4105 1 28 $param->{'bar_solid'} ||= 0
4106 2 27 $param->{'bar_direction'} ||= ''
4107 1 28 $param->{'bar_negative_color'} ||= '#FF0000'
4108 1 28 $param->{'bar_negative_border_color'} ||= '#FF0000'
4109 1 28 $param->{'bar_negative_color_same'} ||= 0
4110 1 28 $param->{'bar_negative_border_color_same'} ||= 0
4111 2 27 $param->{'bar_axis_position'} ||= ''
4112 1 28 $param->{'bar_axis_color'} ||= '#000000'
4292 29 19 $_[4] || {}
4485 2 38 $user_data->{'total_value'} || 0
4626 9 49 $param->{'type'} || 'line'
4699 2 56 $param->{'empty_cells'} || ''
4722 38 20 $param->{'style'} || 0
5344 7279 30075 shift() || 0
5389 13198 46970 shift() || 0
5525 0 3 $options->{'x_offset'} || 0
5526 0 3 $options->{'y_offset'} || 0
5527 2 1 $options->{'x_scale'} || 1
5528 2 1 $options->{'y_scale'} || 1
5529 2 1 $options->{'object_position'} || 1
5533 25 370 $_[3] || 0
5534 25 370 $_[4] || 0
5535 1 394 $_[5] || 1
5536 1 394 $_[6] || 1
5537 1 394 $_[7] || 1
5687 0 0 $cell->[3] || 0
5692 0 0 $cell->[4] || 0
5741 7 27 $options->{'x_offset'} || 0
5742 2 32 $options->{'y_offset'} || 0
5743 1 33 $options->{'x_scale'} || 1
5744 1 33 $options->{'y_scale'} || 1
5745 3 31 $options->{'object_position'} || 2
5751 12 68 $_[3] || 0
5752 12 68 $_[4] || 0
5753 5 75 $_[5] || 1
5754 5 75 $_[6] || 1
5755 5 75 $_[7] || 2
5946 28 17 $_[3] || 0
5947 28 17 $_[4] || 0
5953 0 45 $_[7] || 1
5958 73 17 $shape->{'_id'} || 0
7079 156 45 $_[0] || 0
7080 170 31 $_[1] || 0
7083 19 182 $_[4] || 0
7084 1 200 $_[5] || 0
7085 0 201 $_[6] || 0
7285 290 10 shift() || 0
7418 281 4133 shift() || 0
7419 53 4361 shift() || 0
7420 4 4410 shift() || 0
7421 369 4045 shift() || 0
9236 4 0 $param->{'value'} || 10

or 3 conditions

line l !l&&r !l&&!r condition
739 15 30 21 shift() || $row
740 14 30 22 shift() || $col
1149 1 0 5 $_[1] || $_[0]
1187 1 0 2 $_[1] || $_[0]
1303 0 0 25 $col < $col_first or $col > $col_last
1311 19 6 0 @tokens == 3 or @tokens == 7
1375 0 0 14 $col < $col_first or $col > $col_last
1506 0 0 4 $value =~ /\D/ or $value < 1
0 0 4 $value =~ /\D/ or $value < 1 or $value > 500
1767 0 0 3 $scale < 10 or $scale > 400
1788 0 0 3 $scale < 10 or $scale > 400
2098 0 0 3952 $error ||= $ret
2144 0 0 5835 $error ||= $ret
2411 3 7 70 $token =~ /^\s/ or $token =~ /\s$/
2811 4 5 66 $url =~ /^\w:/ or $url =~ /^\\\\/
2823 1 0 82 length $url > $max_url or length $tmp_url_str > $max_url
3031 58 155 438 $year % 4 == 0 and $year % 100 or $year % 400 == 0
3036 6 0 645 $year < $epoch or $year > 9999
3037 4 2 639 $month < 1 or $month > 12
3038 2 4 633 $day < 1 or $day > $mdays[$month - 1]
3123 5 1 0 shift() || $self->{'_original_row_height'}
3219 0 1 6 $type eq 'array_formula' or $type eq 'blank'
1 1 5 $type eq 'array_formula' or $type eq 'blank' or $type eq 'rich_string'
3422 2 15 50 $param->{'validate'} eq 'none' or $param->{'validate'} eq 'list'
17 1 49 $param->{'validate'} eq 'none' or $param->{'validate'} eq 'list' or $param->{'validate'} eq 'custom'
3469 41 1 25 $param->{'criteria'} eq 'between' or $param->{'criteria'} eq 'notBetween'
3504 5 2 60 $param->{'validate'} eq 'date' or $param->{'validate'} eq 'time'
3771 2 0 147 $param->{'type'} eq 'date' or $param->{'type'} eq 'time'
3907 1 12 136 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'}
12 1 135 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'} or $param->{'bar_solid'}
1 1 134 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'} or $param->{'bar_solid'} or $param->{'bar_border_color'}
1 1 133 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'} or $param->{'bar_solid'} or $param->{'bar_border_color'} or $param->{'bar_negative_color'}
1 1 132 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'} or $param->{'bar_solid'} or $param->{'bar_border_color'} or $param->{'bar_negative_color'} or $param->{'bar_negative_color_same'}
1 1 131 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'} or $param->{'bar_solid'} or $param->{'bar_border_color'} or $param->{'bar_negative_color'} or $param->{'bar_negative_color_same'} or $param->{'bar_negative_border_color'}
1 1 130 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'} or $param->{'bar_solid'} or $param->{'bar_border_color'} or $param->{'bar_negative_color'} or $param->{'bar_negative_color_same'} or $param->{'bar_negative_border_color'} or $param->{'bar_negative_border_color_same'}
1 1 129 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'} or $param->{'bar_solid'} or $param->{'bar_border_color'} or $param->{'bar_negative_color'} or $param->{'bar_negative_color_same'} or $param->{'bar_negative_border_color'} or $param->{'bar_negative_border_color_same'} or $param->{'bar_no_border'}
1 2 127 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'} or $param->{'bar_solid'} or $param->{'bar_border_color'} or $param->{'bar_negative_color'} or $param->{'bar_negative_color_same'} or $param->{'bar_negative_border_color'} or $param->{'bar_negative_border_color_same'} or $param->{'bar_no_border'} or $param->{'bar_axis_position'}
2 1 126 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'} or $param->{'bar_solid'} or $param->{'bar_border_color'} or $param->{'bar_negative_color'} or $param->{'bar_negative_color_same'} or $param->{'bar_negative_border_color'} or $param->{'bar_negative_border_color_same'} or $param->{'bar_no_border'} or $param->{'bar_axis_position'} or $param->{'bar_axis_color'}
1 2 124 $self->{'_use_data_bars_2010'} or $param->{'data_bar_2010'} or $param->{'bar_solid'} or $param->{'bar_border_color'} or $param->{'bar_negative_color'} or $param->{'bar_negative_color_same'} or $param->{'bar_negative_border_color'} or $param->{'bar_negative_border_color_same'} or $param->{'bar_no_border'} or $param->{'bar_axis_position'} or $param->{'bar_axis_color'} or $param->{'bar_direction'}
4102 1 28 0 $param->{'bar_border_color'} ||= $param->{'bar_color'}
4343 0 0 1 not $name =~ /^[\w\\][\w\\.]*$/ or $name =~ /^\d/
4355 0 0 1 $name =~ /^[rcRC]$/ or $name =~ /^[rcRC]\d+[rcRC]\d+$/
5051 928 0 15656 $ignore_row || $ignore_col
5057 814 19 14818 not defined $self->{'_dim_rowmin'} or $row < $self->{'_dim_rowmin'}
5061 814 3863 10974 not defined $self->{'_dim_rowmax'} or $row > $self->{'_dim_rowmax'}
5068 823 17 14859 not defined $self->{'_dim_colmin'} or $col < $self->{'_dim_colmin'}
5072 823 1495 13381 not defined $self->{'_dim_colmax'} or $col > $self->{'_dim_colmax'}
5541 0 0 398 $chart->{'_already_inserted'} or $chart->{'_combined'} and $chart->{'_combined'}{'_already_inserted'}
5843 17 1 5 $url =~ m[^[fh]tt?ps?://] or $url =~ /^mailto:/
6752 8 9 1019 $self->{'_fit_page'} or $self->{'_filter_on'}
9 2 1017 $self->{'_fit_page'} or $self->{'_filter_on'} or $self->{'_tab_color'}
2 1 1016 $self->{'_fit_page'} or $self->{'_filter_on'} or $self->{'_tab_color'} or $self->{'_outline_changed'}
1 6 1010 $self->{'_fit_page'} or $self->{'_filter_on'} or $self->{'_tab_color'} or $self->{'_outline_changed'} or $self->{'_vba_codename'}
6766 8 2 16 $self->{'_fit_page'} or $self->{'_tab_color'}
2 1 15 $self->{'_fit_page'} or $self->{'_tab_color'} or $self->{'_outline_changed'}
6812 779 9 255 defined $self->{'_dim_rowmin'} || defined $self->{'_dim_colmin'}
6961 52 17 1044 @{$self->{'_panes'};} or @{$self->{'_selections'};}
7228 380 3420 1049162 $self->{'_set_rows'}{$row_num} or $self->{'_table'}{$row_num}
3420 306 1048856 $self->{'_set_rows'}{$row_num} or $self->{'_table'}{$row_num} or $self->{'_comments'}{$row_num}
7292 1 299 0 $self->{'_set_rows'}{$row_num} or $self->{'_table'}{$row_num}
299 0 0 $self->{'_set_rows'}{$row_num} or $self->{'_table'}{$row_num} or $self->{'_comments'}{$row_num}
7387 65632 770 986866 ($row_num + 1) % 16 == 0 or $row_num == $self->{'_dim_rowmax'}
7573 3 0 291 $string =~ /^\s/ or $string =~ /\s$/
9185 1 1 95 $param->{'type'} eq 'containsText' or $param->{'type'} eq 'notContainsText'
2 3 92 $param->{'type'} eq 'containsText' or $param->{'type'} eq 'notContainsText' or $param->{'type'} eq 'beginsWith'
4 3 89 $param->{'type'} eq 'containsText' or $param->{'type'} eq 'notContainsText' or $param->{'type'} eq 'beginsWith' or $param->{'type'} eq 'endsWith'
1 1 77 $param->{'type'} eq 'containsBlanks' or $param->{'type'} eq 'notContainsBlanks'
2 1 76 $param->{'type'} eq 'containsBlanks' or $param->{'type'} eq 'notContainsBlanks' or $param->{'type'} eq 'containsErrors'
2 1 75 $param->{'type'} eq 'containsBlanks' or $param->{'type'} eq 'notContainsBlanks' or $param->{'type'} eq 'containsErrors' or $param->{'type'} eq 'notContainsErrors'
9198 1 28 2 $value =~ /(\$?)([A-Z]{1,3})(\$?)(\d+)/ or $value =~ /^([+-]?)(?=\d|\.\d)\d*(\.\d*)?([Ee]([+-]?\d+))?$/
9503 1 1 48 $type eq 'min' or $type eq 'max'
2 19 29 $type eq 'min' or $type eq 'max' or $type eq 'autoMin'
20 20 9 $type eq 'min' or $type eq 'max' or $type eq 'autoMin' or $type eq 'autoMax'
9596 11 11 1011 $has_data_bars or $has_sparklines
9687 1 1 23 $data_bar->{'bar_no_border'} or $data_bar->{'bar_negative_border_color_same'}
9771 1 1 23 $data_bar->{'bar_no_border'} or $data_bar->{'bar_negative_border_color_same'}