MDL-81522 phpunit: Add missing void return type to all tests

While this change is not 100% required now, it's good habit
and we are checking for it since Moodle 4.4.

All the changes in this commit have been applied automatically
using the moodle.PHPUnit.TestReturnType sniff and are, exclusively
adding the ": void" return types when missing.
This commit is contained in:
Eloy Lafuente (stronk7)
2024-06-11 12:18:04 +02:00
parent db07c09afc
commit 1093256560
1360 changed files with 9928 additions and 9928 deletions
+2 -2
View File
@@ -39,7 +39,7 @@ class indicator_test extends \advanced_testcase {
* @dataProvider validate_calculated_value
* @return null
*/
public function test_validate_calculated_value($indicatorclass, $returnedvalue) {
public function test_validate_calculated_value($indicatorclass, $returnedvalue): void {
$indicator = new $indicatorclass();
list($values, $unused) = $indicator->calculate([1], 'notrelevanthere');
$this->assertEquals($returnedvalue, $values[0]);
@@ -66,7 +66,7 @@ class indicator_test extends \advanced_testcase {
* @dataProvider validate_calculated_value_exceptions
* @return null
*/
public function test_validate_calculated_value_exceptions($indicatorclass, $willreturn) {
public function test_validate_calculated_value_exceptions($indicatorclass, $willreturn): void {
$indicator = new $indicatorclass();
$indicatormock = $this->getMockBuilder(get_class($indicator))