-
-
Notifications
You must be signed in to change notification settings - Fork 6.9k
Closed
Labels
Description
What steps will reproduce the problem?
I'm overriding Mailer class with my own and use it to create queue of emails.
When I run tests, it seems to be using another class (Codeception\Lib\Connector\Yii2\TestMailer).
What is the expected result?
Use custom Mailing class.
What do you get instead?
Exception with message for each test where mailing class with custom method myOwnMathod()
is used:
[yii\base\UnknownMethodException] Calling unknown method: Codeception\Lib\Connector\Yii2\TestMailer::myOwnMathod()
Where myOwnMethod()
is defined in my overriten mailer class, but as in tests it is using \yii\swiftmailer\Mailer
, which certainly is missing that method.
Is there a way to set-up custom mailing class for tests?
Q | A |
---|---|
Yii version | 2.0.12 |
PHP version | 5.5+ |
Operating system | Ubuntu 14.04 |