Skip to content

Emit events for E_* and E_USER_* triggered in data provider methods #5775

@nikophil

Description

@nikophil
Q A
PHPUnit version 11.0.9
PHP version 8.3.4
Installation Method Composer / PHAR

Summary

Hello,

I don't know if it is a known issue, I've looked for a related one and did not find it.

It seems that a deprecation triggered in a data provider will not be reported by phpunit.

Current behavior

If we call @trigger_error('some deprecation', \E_USER_DEPRECATED) in a data provider, no deprecation warning is displayed. Even with ignoreSuppressionOfDeprecations="true"

How to reproduce

call trigger_error('some deprecation', \E_USER_DEPRECATED) in a data provider

Expected behavior

a D should be displayed instead of a .

Metadata

Metadata

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions