Skip to content

Commit

Permalink
Merge pull request #62 from wesolydexter/blacklist-fix
Browse files Browse the repository at this point in the history
Blacklist: Fix building of the excludes list
  • Loading branch information
shulard authored Aug 12, 2024
2 parents 944f7d0 + 18bb622 commit cfe2fd1
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/Listener/CodeCoverageListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -154,15 +154,19 @@ public function beforeSuite(SuiteEvent $event): void
foreach ($this->options['blacklist'] as $option) {
$settings = $this->filterDirectoryParams($option);
if (!empty($settings['suffix']) || !empty($settings['prefix'])) {
$excludes = $excludes + (new FileIteratorFacade())->getFilesAsArray(
$settings['directory'],
$settings['suffix'],
$settings['prefix']
$excludes = array_merge(
$excludes,
(new FileIteratorFacade())->getFilesAsArray(
$settings['directory'],
$settings['suffix'],
$settings['prefix']
)
);
} else {
$excludes[] = $settings['directory'];
}
}
$excludes = array_unique($excludes);

foreach ($this->options['whitelist'] as $option) {
$settings = $this->filterDirectoryParams($option);
Expand Down

0 comments on commit cfe2fd1

Please sign in to comment.