本文整理汇总了PHP中Mage_Core_Model_Email_Template::setSenderName方法的典型用法代码示例。如果您正苦于以下问题:PHP Mage_Core_Model_Email_Template::setSenderName方法的具体用法?PHP Mage_Core_Model_Email_Template::setSenderName怎么用?PHP Mage_Core_Model_Email_Template::setSenderName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Mage_Core_Model_Email_Template
的用法示例。
在下文中一共展示了Mage_Core_Model_Email_Template::setSenderName方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: setUp
protected function setUp()
{
$this->_mail = $this->getMock('Zend_Mail', array('send', 'addTo', 'addBcc', 'setReturnPath', 'setReplyTo'), array('utf-8'));
$this->_model = $this->getMock('Mage_Core_Model_Email_Template', array('_getMail'));
$this->_model->expects($this->any())->method('_getMail')->will($this->returnCallback(array($this, 'getMail')));
$this->_model->setSenderName('sender')->setSenderEmail('sender@example.com')->setTemplateSubject('Subject');
}
示例2: setUp
protected function setUp()
{
Mage_Core_Utility_Theme::registerDesignMock();
Mage::getDesign()->setDefaultDesignTheme();
$this->_mail = $this->getMock('Zend_Mail', array('send', 'addTo', 'addBcc', 'setReturnPath', 'setReplyTo'), array('utf-8'));
$this->_model = $this->getMockBuilder('Mage_Core_Model_Email_Template')->setMethods(array('_getMail'))->setConstructorArgs(array($this->getMockBuilder('Mage_Core_Model_Event_Manager')->disableOriginalConstructor()->getMock(), $this->getMockBuilder('Mage_Core_Model_Cache')->disableOriginalConstructor()->getMock(), Mage::getObjectManager()->create('Magento_Filesystem')))->getMock();
$this->_model->expects($this->any())->method('_getMail')->will($this->returnCallback(array($this, 'getMail')));
$this->_model->setSenderName('sender')->setSenderEmail('sender@example.com')->setTemplateSubject('Subject');
}