public function PHP_CodeCoverage_Filter::isFiltered in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/phpunit/php-code-coverage/src/CodeCoverage/Filter.php \PHP_CodeCoverage_Filter::isFiltered()
Checks whether or not a file is filtered.
When the whitelist is empty (default), blacklisting is used. When the whitelist is not empty, whitelisting is used.
Parameters
string $filename:
Return value
bool
Throws
File
- vendor/
phpunit/ php-code-coverage/ src/ CodeCoverage/ Filter.php, line 204
Class
- PHP_CodeCoverage_Filter
- Filter for blacklisting and whitelisting of code coverage information.
Code
public function isFiltered($filename) {
if (!$this
->isFile($filename)) {
return true;
}
$filename = realpath($filename);
if (!empty($this->whitelistedFiles)) {
return !isset($this->whitelistedFiles[$filename]);
}
return isset($this->blacklistedFiles[$filename]);
}