We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 8704991 + b6a69d3 commit dc37fbfCopy full SHA for dc37fbf
lib/TAP/Parser/SourceHandler/Perl.pm
@@ -92,7 +92,8 @@ sub can_handle {
92
return 0.8 if $file->{lc_ext} eq '.t'; # vote higher than Executable
93
return 0.9 if $file->{lc_ext} eq '.pl';
94
95
- return 0.75 if $file->{dir} =~ /^t\b/; # vote higher than Executable
+ my @dirs = File::Spec->splitdir($file->{dir});
96
+ return 0.75 if scalar(@dirs) && $dirs[0] eq 't'; # vote higher than Executable
97
98
# backwards compat, always vote:
99
return 0.25;
0 commit comments