@@ -1697,6 +1697,7 @@ sub findFileList
1697
1697
my $dirSummary = $self -> [1];
1698
1698
my $owner = $self -> [0];
1699
1699
my @files ;
1700
+ my $skipped = 0;
1700
1701
foreach my $file ($dirSummary -> sources()) {
1701
1702
my $source = $dirSummary -> get_source($file );
1702
1703
next unless $source -> contains_owner($owner );
@@ -1727,7 +1728,8 @@ sub findFileList
1727
1728
if ($all ||
1728
1729
0 != $missed ||
1729
1730
0 != $br_missed ||
1730
- 0 != $fn_missed ) {
1731
+ 0 != $fn_missed ||
1732
+ 0 != $mcdc_missed ) {
1731
1733
1732
1734
push (@files ,
1733
1735
[$file ,
@@ -1736,9 +1738,11 @@ sub findFileList
1736
1738
[$mcdc_missed , $mcdc_total , $mcdcCb ],
1737
1739
[$fn_missed , $fn_total , $funcCb ]
1738
1740
]);
1741
+ } else {
1742
+ ++$skipped ;
1739
1743
}
1740
1744
}
1741
- return @files ;
1745
+ return [ $skipped , @files ] ;
1742
1746
}
1743
1747
1744
1748
sub secondaryElementFileData
@@ -1831,6 +1835,7 @@ sub findFileList
1831
1835
my $dirSummary = $self -> [2];
1832
1836
my $ageval = $self -> [1];
1833
1837
my @files ;
1838
+ my $skipped = 0;
1834
1839
foreach my $file ($dirSummary -> sources()) {
1835
1840
my $source = $dirSummary -> get_source($file );
1836
1841
@@ -1869,9 +1874,11 @@ sub findFileList
1869
1874
[$mcdc_missed , $mcdc_total , $mcdcCb ],
1870
1875
[$fn_missed , $fn_total , $funcCb ]
1871
1876
]);
1877
+ } else {
1878
+ ++$skipped ;
1872
1879
}
1873
1880
}
1874
- return @files ;
1881
+ return [ $skipped , @files ] ;
1875
1882
}
1876
1883
1877
1884
sub secondaryElementFileData
@@ -12819,6 +12826,7 @@ sub write_file_table(*$$$$$$)
12819
12826
# rows that the $primary cell will span
12820
12827
12821
12828
my @secondaryRows ;
12829
+ my $skippedSecondaryRows = 0;
12822
12830
12823
12831
if (defined ($showBinDetail )) {
12824
12832
@@ -12901,7 +12909,8 @@ sub write_file_table(*$$$$$$)
12901
12909
}
12902
12910
} # if showBinDetail
12903
12911
elsif ($primary_key ne ' name' ) {
12904
- push (@secondaryRows , $primaryCb -> findFileList($all ));
12912
+ ($skippedSecondaryRows , @secondaryRows ) =
12913
+ @{$primaryCb -> findFileList($all )};
12905
12914
}
12906
12915
12907
12916
my ($found , $hit , $fn_found , $fn_hit ,
@@ -12965,16 +12974,16 @@ sub write_file_table(*$$$$$$)
12965
12974
$cbStruct , SummaryInfo::FUNCTION_DATA
12966
12975
]);
12967
12976
}
12968
- my $elide_secondary_header =
12969
- $compactSummaryTables && (scalar (@secondaryRows ) == 1);
12977
+ my $elide_secondary_header = $compactSummaryTables &&
12978
+ (scalar (@secondaryRows ) == 1 && $skippedSecondaryRows == 0 );
12970
12979
$suppressedSecondaryHeader ||= $elide_secondary_header ;
12971
12980
if (!$elide_secondary_header ) {
12972
12981
# pass 'dirSummary' to print method: we omit the 'owner' column if
12973
12982
# none of the files in this directory have any owner information
12974
12983
# (i.e., none of them are found in the repo)
12975
12984
my $numRows = (1 + scalar (@secondaryRows ));
12976
12985
my $asterisk ;
12977
- if ($elideEmptyRows && 1 == $numRows ) {
12986
+ if ($elideEmptyRows && ( 1 == $numRows || $skippedSecondaryRows ) ) {
12978
12987
$asterisk = ' ∗' ;
12979
12988
$suppressedEmptyRow = 1;
12980
12989
}
@@ -13064,6 +13073,7 @@ sub write_file_table(*$$$$$$)
13064
13073
# no information by eliding the directory part
13065
13074
$name = File::Basename::basename($name );
13066
13075
}
13076
+ $name = apply_prefix($name , @dir_prefix );
13067
13077
write_file_table_entry(*HTML_HANDLE, $base_dir ,
13068
13078
# 'owner' page type - no span, no page link
13069
13079
[$name ,
@@ -13168,7 +13178,7 @@ sub write_file_table(*$$$$$$)
13168
13178
}
13169
13179
foreach my $note (
13170
13180
[ $suppressedEmptyRow ,
13171
- " <sup>∗</sup> 'Detail' entries with no 'missed' coverpoints are elided."
13181
+ " <sup>∗</sup> 'Detail' entries with no 'missed' coverpoints are elided. Use the '--show-owners all' flag to retain them. "
13172
13182
],
13173
13183
[ $suppressedSecondaryHeader ,
13174
13184
' <sup>∗∗</sup> Bin \' Total\' header elided when bin contains only one entry.'
0 commit comments