minor #38191 [PhpUnitBridge] Fix error with ReflectionClass (sanmai)

This PR was merged into the 4.4 branch.

Discussion
----------

[PhpUnitBridge] Fix error with ReflectionClass

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| License       | MIT

Introduced in #38094. Wish I know how I missed that.

Commits
-------

ed1bffeed7 [PhpUnitBridge] Fix error with ReflectionClass
This commit is contained in:
Nicolas Grekas 2020-09-15 10:18:57 +02:00
commit 13656916d1

View File

@ -109,7 +109,7 @@ class CoverageListenerTrait
// Exclude internal classes; PHPUnit 9.1+ is picky about tests covering, say, a \RuntimeException
$covers = array_filter($covers, function ($class) {
$reflector = new ReflectionClass($class);
$reflector = new \ReflectionClass($class);
return $reflector->isUserDefined();
});