Example #1
0
 public function testGetImageUrl()
 {
     $product = new Mage_Catalog_Model_Product();
     $this->assertStringEndsWith('placeholder/image.jpg', $this->_helper->getImageUrl($product));
     $product->setImage('test_image.png');
     $this->assertStringEndsWith('/test_image.png', $this->_helper->getImageUrl($product));
 }
Example #2
0
 public function testGetImageUrl()
 {
     /** @var $product Mage_Catalog_Model_Product */
     $product = Mage::getModel('Mage_Catalog_Model_Product');
     $this->assertStringEndsWith('placeholder/image.jpg', $this->_helper->getImageUrl($product));
     $product->setImage('test_image.png');
     $this->assertStringEndsWith('/test_image.png', $this->_helper->getImageUrl($product));
 }