moodle/analytics
Eloy Lafuente (stronk7) 81407f18ec MDL-71036 phpunit: Mock->setMethods() silently deprecated
The current ->setMethods() has been silently (won't emit any
warning) in PHPUnit 9. And will stop working (current plans)
in PHPUnit 10.

Basically the now deprecated method has been split into:

- onlyMethods(): To point to existing methods in the mocked artifact.
- addMethods(): To point to non existing (yet) methods in the mocked
  artifact.

In practice that means that all our current setMethods() calls can be
converted to onlyMethods() (existing) and done. The addMethods() is
mostly useful on development phases, not final testing.

Finally note that <null> isn't accepted anymore as parameter to
double all the methods. Instead empty array [] must be used.

Link: https://github.com/sebastianbergmann/phpunit/issues/3770
2021-03-11 23:04:31 +01:00
..
classes MDL-70898 various: private functions can not be declared final 2021-02-15 16:20:06 +01:00
templates MDL-67735 theme_boost: remove bs2 and bs4alpha compatibility css 2020-08-17 08:16:42 +00:00
tests MDL-71036 phpunit: Mock->setMethods() silently deprecated 2021-03-11 23:04:31 +01:00
lib.php MDL-64786 analytics: Allow renaming models via inplace editable element 2019-04-15 08:22:13 +02:00
upgrade.txt MDL-65284 analytics: Final deprecation get_analysables() 2020-12-16 12:47:52 +01:00