assertEquals may fail if objects have hooked properties that are assigned inside the 'get' hook #6070
Labels
feature/assertion
Issues related to assertions and expectations
type/change-in-php-requires-adaptation
A change in PHP requires a change so that existing PHPUnit functionality continues to work
I am really not sure if it is bug or reasonable behavior but just in case, I used the bug report form.
Summary
The (unexpected?) behavior is observed when working with a property hook, where the property is assigned inside the 'get' hook.
Current behavior
Please see the code in "How to reproduce". The test returns "Failed asserting that two objects are equal."
How to reproduce
Expected behavior
I would expect that the test should pass since in real world we would never see those objects being different.
Composer info | sort
The text was updated successfully, but these errors were encountered: