moodle/favourites/tests
Daniel Ziegenberg 08027e408c
MDL-81281 phpunit: assertObjectHasAttribute is deprecated
To be integrated as part of MDL-81266

When running PHPUnit 9.6 we get the following deprecation warnings:
"assertObjectHasAttribute() is deprecated and will be removed in PHPUnit
10. Refactor your test to use assertObjectHasProperty() instead."

So we replace all instances of assertObjectHasAttribute with
assertObjectHasProperty.

PHPUnit justifies the change with:
> PHPUnit currently refers to "fields" (see above) as "attributes". This
> is (or will become) confusing considering the introduction of
> attributes in PHP 8 and their support in PHPUnit.  PHPUnit will be
> changed to use the term "property" instead of "attribute" where "field"
> is meant.

Signed-off-by: Daniel Ziegenberg <daniel@ziegenberg.at>
2024-03-25 16:21:45 +01:00
..
privacy MDL-73348 phpunit: normalize all privacy provider tests 2021-12-17 14:21:02 +01:00
component_favourite_service_test.php MDL-73971 phpunit: Move more tests to use correct names and namespaces 2022-05-06 18:29:11 +02:00
repository_test.php MDL-81281 phpunit: assertObjectHasAttribute is deprecated 2024-03-25 16:21:45 +01:00
user_favourite_service_test.php MDL-81281 phpunit: assertObjectHasAttribute is deprecated 2024-03-25 16:21:45 +01:00