/** * Register a listener for new emails. * * This calls my PHPUnit before each test it runs. It registers the MailRecorder "plugin" with Swift, so that we * can get a copy of each email that is sent during that test. * * @before */ public function setUpMailTracking() { Mail::getSwiftMailer()->registerPlugin(new MailRecorder($this)); }