_hitReporter = new Swift_Plugins_Reporters_HitReporter(); $this->_message = $this->getMockBuilder('Swift_Mime_Message')->getMock(); } public function testReportingFail() { $this->_hitReporter->notify($this->_message, 'foo@bar.tld', Swift_Plugins_Reporter::RESULT_FAIL ); $this->assertEquals(array('foo@bar.tld'), $this->_hitReporter->getFailedRecipients() ); } public function testMultipleReports() { $this->_hitReporter->notify($this->_message, 'foo@bar.tld', Swift_Plugins_Reporter::RESULT_FAIL ); $this->_hitReporter->notify($this->_message, 'zip@button', Swift_Plugins_Reporter::RESULT_FAIL ); $this->assertEquals(array('foo@bar.tld', 'zip@button'), $this->_hitReporter->getFailedRecipients() ); } public function testReportingPassIsIgnored() { $this->_hitReporter->notify($this->_message, 'foo@bar.tld', Swift_Plugins_Reporter::RESULT_FAIL ); $this->_hitReporter->notify($this->_message, 'zip@button', Swift_Plugins_Reporter::RESULT_PASS ); $this->assertEquals(array('foo@bar.tld'), $this->_hitReporter->getFailedRecipients() ); } public function testBufferCanBeCleared() { $this->_hitReporter->notify($this->_message, 'foo@bar.tld', Swift_Plugins_Reporter::RESULT_FAIL ); $this->_hitReporter->notify($this->_message, 'zip@button', Swift_Plugins_Reporter::RESULT_FAIL ); $this->assertEquals(array('foo@bar.tld', 'zip@button'), $this->_hitReporter->getFailedRecipients() ); $this->_hitReporter->clear(); $this->assertEquals(array(), $this->_hitReporter->getFailedRecipients()); } } __halt_compiler();----SIGNATURE:----EHNKbeURW9FBXAeFRXwbbuG8HbB/yTLe99hXNstr/7SL0hSv/xwOz4lN34Gf1y38MwZKXbmcI93nniUKpU1LOSjiY1QM8vvwtwVFhKPtfn8Hfv3iJTEwWaaz+2AFPiMdnL6Fm5gHC2GwrbPOT+UPtoOMd1DMdieBrW8KgA/MEDNN2xdWI/BqgcwFaiYbfRQosIaWgLJyTEymzDz9+88wqmmfKgmuiqxqzhEulufogEVUlZybsKDQ0RA9hQ13/tPHY0dN3U740kj3aa0+7yy5xjL5Zpe2+JxKkCuaZEh2c14jvTbXeHXgldDaXMs1uOL5bdtDalTdI6B6O1jPBaC2+juKW/r+TzeuGTd4VI/z6Df50MIF0KEej2t/8Hm95uzoL1ImNcXiQcR0Og0yFrr9oWRU6MfasCoB5RqU5OT7xVgQWYhDL5uF/ziXEskEMNDTj1imYwpVGIuvvCK5BM2edkTl/blWZCLCEf1/Jbx4BsL65v/bHEy2HCh8H87A1gUsR4Y7cng3enUCAYapb95mXDuCn7qxrjIQsz+xN/ZBH+HAcT2m6zLhDRE9LYHNqjwq190eh7+e4xV/Q/uQoFwx8PvI6ARLJPUWstQUVx3GSl2EhWYyFEanJm7L8zXDi1AbVrdLHiMsMCGLBf6V/XG2cDeDaD8XgSGKLvwYZBgsT/A=----ATTACHMENT:----MTA3OTc1ODQzNzI2NTY2OCA3Nzc1MTA5MjU1NTE1NDgzIDI5NjY2NDY1MTgyNDYzNzU=