mirror of
https://github.com/moodle/moodle.git
synced 2025-08-06 09:26:35 +02:00
MDL-67673 phpunit: Fix the return type of template methods
All the setup/teardown/pre/post/conditions template methods now are required to return void. This was warned with phpunit 7 and now is enforced. At the same time, fix a few wrong function names, provider data and param types, return statements...
This commit is contained in:
parent
c611109ed7
commit
d81a94807b
421 changed files with 531 additions and 531 deletions
|
@ -43,7 +43,7 @@ class core_badges_badgeslib_testcase extends advanced_testcase {
|
|||
/** @var $assertion2 to define json format for Open badge version 2 */
|
||||
protected $assertion2;
|
||||
|
||||
protected function setUp() {
|
||||
protected function setUp(): void {
|
||||
global $DB, $CFG;
|
||||
$this->resetAfterTest(true);
|
||||
$CFG->enablecompletion = true;
|
||||
|
|
|
@ -45,7 +45,7 @@ class core_badges_external_testcase extends externallib_advanced_testcase {
|
|||
/**
|
||||
* Set up for every test
|
||||
*/
|
||||
public function setUp() {
|
||||
public function setUp(): void {
|
||||
global $DB;
|
||||
$this->resetAfterTest();
|
||||
$this->setAdminUser();
|
||||
|
|
|
@ -48,7 +48,7 @@ require_once($CFG->libdir . '/badgeslib.php');
|
|||
*/
|
||||
class core_badges_privacy_testcase extends provider_testcase {
|
||||
|
||||
public function setUp() {
|
||||
public function setUp(): void {
|
||||
$this->resetAfterTest();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue