MDL-81522 phpunit: Add a few non-void return types to tests
This is the final (3rd) commit, where we are adding missing return types to a few tests (using @depends) which return types are non-void, but something really returned (for consume by the dependent test).
This commit is contained in:
@@ -422,7 +422,7 @@ class advanced_test extends \advanced_testcase {
|
||||
$this->assertEquals(count($processors1) + 1, count($processors3));
|
||||
}
|
||||
|
||||
public function test_message_redirection() {
|
||||
public function test_message_redirection(): \phpunit_message_sink {
|
||||
$this->preventResetByRollback(); // Messaging is not compatible with transactions...
|
||||
$this->resetAfterTest(false);
|
||||
|
||||
@@ -544,7 +544,7 @@ class advanced_test extends \advanced_testcase {
|
||||
/**
|
||||
* @depends test_message_redirection
|
||||
*/
|
||||
public function test_message_redirection_noreset($sink): void {
|
||||
public function test_message_redirection_noreset(\phpunit_message_sink $sink): void {
|
||||
if ($this->isInIsolation()) {
|
||||
$this->markTestSkipped('State cannot be carried over between tests in isolated tests');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user