Skip to content

Provide a way to stop execution at a particular deprecation #5954

@nicolas-grekas

Description

@nicolas-grekas

Deprecation are sometimes hard to track. Figuring the exact stack trace for one particular deprecation is really useful to understand how it comes up and fix it.

It would be awesome to have a command line option (or similar) to tell phpunit to stop and display its stacktrace when a specific deprecation occurs. The match would happen by checking the deprecation message.

For example:

phpunit --stop-on-deprecation="part of the deprecation message"

For sinpiration this capability exists when using Symfony's phpunit-brigde, as documented at https://symfony.com/doc/current/components/phpunit_bridge.html#configuration

Metadata

Metadata

Labels

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions