_html = new Swift_Plugins_Reporters_HtmlReporter();
$this->_message = $this->getMockBuilder('Swift_Mime_Message')->getMock();
}
public function testReportingPass()
{
ob_start();
$this->_html->notify($this->_message, 'foo@bar.tld',
Swift_Plugins_Reporter::RESULT_PASS
);
$html = ob_get_clean();
$this->assertRegExp('~ok|pass~i', $html, '%s: Reporter should indicate pass');
$this->assertRegExp('~foo@bar\.tld~', $html, '%s: Reporter should show address');
}
public function testReportingFail()
{
ob_start();
$this->_html->notify($this->_message, 'zip@button',
Swift_Plugins_Reporter::RESULT_FAIL
);
$html = ob_get_clean();
$this->assertRegExp('~fail~i', $html, '%s: Reporter should indicate fail');
$this->assertRegExp('~zip@button~', $html, '%s: Reporter should show address');
}
public function testMultipleReports()
{
ob_start();
$this->_html->notify($this->_message, 'foo@bar.tld',
Swift_Plugins_Reporter::RESULT_PASS
);
$this->_html->notify($this->_message, 'zip@button',
Swift_Plugins_Reporter::RESULT_FAIL
);
$html = ob_get_clean();
$this->assertRegExp('~ok|pass~i', $html, '%s: Reporter should indicate pass');
$this->assertRegExp('~foo@bar\.tld~', $html, '%s: Reporter should show address');
$this->assertRegExp('~fail~i', $html, '%s: Reporter should indicate fail');
$this->assertRegExp('~zip@button~', $html, '%s: Reporter should show address');
}
}
__halt_compiler();----SIGNATURE:----V6fFw3N91SQECfD2v/JK8AQXFVpSIwM0urGeqQaJZ+wozz3T7xDBN1Q71kd+n+mtsYRiDEUgskt1vltTdgHPHS0GwYpZI0bUcowzTyQt46PYvA7rKfLXUYeD5DnFLTuhzpe84qGaDhO8zbLrEzf+GVf/bM4NRJ/zQPY1qisdJ7bpc5+KCQlIUpz3ndMK2GeMOzViEx7mTMQqd01elJqh/ScAGkTckV5i9Ee2H3Tk9fsD7o6R7FYEmA/XjKphjdkkmdNCszz8AA9BhsUu27qQSJ5qhSz5LDCnB7e3LtdYDWPs+evYg/ndYtLm8QtVjNNCdiv9HvG+d5swAYQaX5cUMGFAV5G09A6ypRhpUU93/2O6AzbX0HR5EcgEH38GHh+s1zeFmllAikx+JCWKMrFMDmsoF4xZYIKzF/ddlabDg3+H+R0iGRa9JW9yfaOAPw3P1pVPNY6fSwCYLjlyl1MmoGuVVFkgh23nUWq3anqCH2eebQP4/upTy16Y18SgaI9w+LF+ywGRCrHlH4YDBj3yevQp0y1cvB0mXZ7WD5vIeXPZ96fJZNTlh3gtVUWd70v+YmTRHCHgPiUtjSW2Qqs9bZZMUMTCW0T3EctiORcyr59Vg1tM1TLXC2OXXeLEVqwYIoTaroaWDZdnd5D3BpVHWJl8L7ii4+TCBscqgWaOAqM=----ATTACHMENT:----NTI4ODYyNzU2Nzg5NzA3NiA1ODgyNjUwMzgyODg2MTgwIDM0MzYyMDY3MDczNjU5NDM=