Closed Swanty closed 1 year ago
The built in functions only work for the primary component. Making it work for all Mailer components would require changing the api since you would need to tell which component did the sending.
You could create your own helper functions to work with other Mailer instances. I'm not sure this use case belongs in the built in functions.
Makes sense, thank you :bow:
Hi, we have project with a global
mailer
(for system messages) and then for each client we build a new mailer instance depending on their mail settingsHow to test multiple mailer instances by using
seeEmailIsSent
andgrabLastSentEmail
functions?Based on #31 it seems not possible?
Currently we mock
\yii\symfonymailer\Mailer::class
to save messages for testing, but would be much nicer if we could use the built-in functions :pray: