codeception-mailcatcher-module
codeception-mailcatcher-module copied to clipboard
Allow codeception 5
These were the changes I had to do to make this work with codeception 5.
I've ran the whole test suite in a project (private) and had no issues.
- [x] needs v5 release of codeception https://github.com/Codeception/Codeception/releases
- [x] Update compoer.json codeception to
^5.0
Codeception v5 does not support php <8 https://github.com/Codeception/Codeception/blob/5.0.0-RC3/composer.json So I removed it from composer.json and the tests
Will have to wait for v5 to be released, since as of writing this the latest version is RC3 https://github.com/Codeception/Codeception/releases
We can run the tests with 5.0.0-RC3 in composer.json to see if they pass (and it will be updated when v5 is released)
Codeception 5 was released today https://github.com/Codeception/Codeception/releases
Updated composer with codeception v5 Also added to allow v3 of codeception/module-asserts https://github.com/Codeception/module-asserts/releases
Test failure @akalineskou
Hit a bit of a problem here in trying to support both Codeception v4 and v5 in Module
class:
In Codeception v4, $config
has no type:
https://github.com/Codeception/Codeception/blob/18beff367306d66f955add5fa74e590a5210e219/src/Codeception/Module.php#L57
However, in v5 it does:
https://github.com/Codeception/Codeception/blob/667dfa4acde020b4328aa5570818cc8cb305f8c4/src/Codeception/Module.php#L49
We need to extend $config
, so how do we do so without causing a PHP fatal error due to not matching the typing of the parent?
You could release version 3 which would not support codeception 4... I mean at some point people will have to upgrade...
You could release version 3 which would not support codeception 4... I mean at some point people will have to upgrade...
@Jamesking56 Please do that :)
Codeception v5 is now supported in v3.0.0