mirror of
https://github.com/moodle/moodle.git
synced 2025-08-10 03:16:42 +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
|
@ -36,7 +36,7 @@ global $CFG;
|
|||
*/
|
||||
class mod_book_events_testcase extends advanced_testcase {
|
||||
|
||||
public function setUp() {
|
||||
public function setUp(): void {
|
||||
$this->resetAfterTest();
|
||||
}
|
||||
|
||||
|
|
|
@ -39,7 +39,7 @@ require_once($CFG->dirroot . '/mod/book/lib.php');
|
|||
*/
|
||||
class mod_book_lib_testcase extends advanced_testcase {
|
||||
|
||||
public function setUp() {
|
||||
public function setUp(): void {
|
||||
$this->resetAfterTest();
|
||||
$this->setAdminUser();
|
||||
}
|
||||
|
|
|
@ -43,7 +43,7 @@ class mod_book_search_testcase extends advanced_testcase {
|
|||
*/
|
||||
protected $bookchapterareaid = null;
|
||||
|
||||
public function setUp() {
|
||||
public function setUp(): void {
|
||||
$this->resetAfterTest(true);
|
||||
set_config('enableglobalsearch', true);
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@ global $CFG;
|
|||
*/
|
||||
class booktool_exportimscp_events_testcase extends advanced_testcase {
|
||||
|
||||
public function setUp() {
|
||||
public function setUp(): void {
|
||||
$this->resetAfterTest();
|
||||
}
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@ require_once($CFG->dirroot.'/mod/book/tool/importhtml/locallib.php');
|
|||
*/
|
||||
class booktool_importhtml_locallib_testcase extends advanced_testcase {
|
||||
|
||||
public function setUp() {
|
||||
public function setUp(): void {
|
||||
$this->resetAfterTest();
|
||||
}
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@ global $CFG;
|
|||
*/
|
||||
class booktool_print_events_testcase extends advanced_testcase {
|
||||
|
||||
public function setUp() {
|
||||
public function setUp(): void {
|
||||
$this->resetAfterTest();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue