-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Open
Labels
feature/assertionIssues related to assertions and expectationsIssues related to assertions and expectationstype/enhancementA new idea that should be implementedA new idea that should be implemented
Description
When I write a test, that expects a boolean as return value, but - for some reason - does not get a boolean from the tested code, but a big array or an object, the whole object is dumped into the failure description. This potentially is a big waste of memory and makes reading the output quite hard.
Examples:
- src/Framework/Constraint/Boolean/IsFalse.php
- src/Framework/Constraint/Boolean/IsTrue.php
My feature request would be:
- I would like just to get the message that its an object or an array, which was compared with false or true in this example instead of a dumped object / array
- alternatively, if rejected, I want to have an option not to dump objects recursively at all (as its currently implemented in \PHPUnit\Framework\Constraint\Constraint::failureDescription) or even to choose an exporter logic on my own.
Metadata
Metadata
Assignees
Labels
feature/assertionIssues related to assertions and expectationsIssues related to assertions and expectationstype/enhancementA new idea that should be implementedA new idea that should be implemented