Prior to PHPUnit 11.1, the #[CoversClass] and #[UsesClass] attributes could target traits. This was not intentional, which is why there were no tests covering this behaviour. This behaviour was broken while working on #5733 and this breakage was only noticed after the release: Roave/BetterReflection#1420 (comment).
Prior to PHPUnit 11.1, the
#[CoversClass]and#[UsesClass]attributes could target traits. This was not intentional, which is why there were no tests covering this behaviour. This behaviour was broken while working on #5733 and this breakage was only noticed after the release: Roave/BetterReflection#1420 (comment).