Declaration of MimeMailTest::testMail() must be compatible PhpMailTest::testMail()

Created on 31 December 2024, 23 days ago

Problem/Motivation

Running phpunit produces this error:
PHP Fatal error: Declaration of MimeMailTest::testMail() must be compatible with PhpMailTest::testMail(): void in mimemail/tests/src/Unit/MimeMailTest.php on line 47

Proposed resolution

Add void to make compatible.

πŸ› Bug report
Status

Active

Component

Code

Created by

πŸ‡¨πŸ‡¦Canada mmaranao Calgary, AB

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @mmaranao
  • πŸ‡¨πŸ‡¦Canada mmaranao Calgary, AB

    Patch to fix compatibility.

  • πŸ‡ΊπŸ‡ΈUnited States tr Cascadia

    Well first, not a bug. Core changes things all the time, and the Mime Mail code was correct when written, before the core change. Something like this is always a "Task".

    Second, this was already fixed, in πŸ“Œ [10.3] Add void return typehints to all test methods Fixed , back in July, only 1 week after core made that change.

    Fixed point module releases like 8.x-1.0-alpha6 cannot be changed. Ever. Changes to modules are made in the -dev version, and later releases are made from the -dev version. Therefore, before you make a patch please checkout the latest -dev version and create your patch against the latest -dev version. In this case, however, the fix is already in -dev.

Production build 0.71.5 2024