particleflux/codeception-email

Email Module for codeception

Maintainers

Package info

codeberg.org/particleflux/codeception-email

Issues

pkg:composer/particleflux/codeception-email

Transparency log

Statistics

Installs: 54

Dependents: 0

Suggesters: 0

0.0.1 2026-07-24 19:07 UTC

This package is not auto-updated.

Last update: 2026-07-25 15:30:09 UTC


README

A helper to test emails sent during Codeception tests.

No mailcatcher or mailtrap needed, relies on existing modules grabLastSentEmail(). Or, theoretically, you can just pass in raw mails from wherever.

Installation

composer require --dev particleflux/codeception-email

Usage

Enable the module in your codeception suite, e.g.:

modules:
    enabled:
        - Asserts
        - particleflux\Codeception\Module\Email
        - Yii2   

Example usage:

$I->seeEmailIsSent(); // from yii2 module

// grabLastSentEmail() is yii2 module
$I->openMail((string) $I->grabLastSentEmail());

$I->seeInTo('tester2@hackthe.codes');
$I->seeSubjectContains('Verify your email');

$I->seeTextBodyContains("/site/verify-email?token=12345");