Hi Hi, I would suggest github.com/proxied-mail/proxiedmail-php-client to test emails with Codeception.
It's a package of my product, but I spent some time making it good for email testing, especially with Codeception.
Also, I made the example of using this package with Codeception - github.com/proxied-mail/codeception-email-testing-example. There is also a link to the article if you need a detailed guide.
It will look like this
$config = new Config();
$config->setApiToken($proxiedMailApiToken);
$api = PxdMailApinitializer::init($config);
$proxyEmail = $api->createProxyEmail();
$I->amOnPage('/email-playground/index.html');
$I->fillField(['id' => 'name'], 'Tester');
$I->fillField(['id' => 'email'], $proxyEmail->getProxyAddress());
$I->executeJS('document.getElementById("submit").click()');
sleep(3);
$I->canSee('Check your mailbox');
$firstEmail = $api->waitUntilFirstEmail($proxyEmail->getId());
$I->assertSame($firstEmail->getSubject(), 'Code confirmation');
$text = $firstEmail->getPayload()['stripped-text'];
//find code after "Your confirmation code is"
preg_match('/Your confirmation code is ([0-9]+)/', $text, $matches);
$code = $matches[1];
Also, I'm here and I'm ready to help just in case.