/**
  * {@inheritdoc}
  */
 public function getPriceInfo(\Magento\Catalog\Model\Product $saleableItem)
 {
     $pluginInfo = $this->pluginList->getNext($this->subjectType, 'getPriceInfo');
     if (!$pluginInfo) {
         return parent::getPriceInfo($saleableItem);
     } else {
         return $this->___callPlugins('getPriceInfo', func_get_args(), $pluginInfo);
     }
 }
Beispiel #2
0
 /**
  * Get product Price Info object
  *
  * @return \Magento\Framework\Pricing\PriceInfo\Base
  */
 public function getPriceInfo()
 {
     if (!$this->_priceInfo) {
         $this->_priceInfo = $this->_catalogProductType->getPriceInfo($this);
     }
     return $this->_priceInfo;
 }
Beispiel #3
0
 public function testGetPriceInfo()
 {
     $mockedProduct = $this->getMockedProduct();
     $expectedResult = '\\Magento\\Framework\\Pricing\\PriceInfoInterface';
     $this->assertInstanceOf($expectedResult, $this->_model->getPriceInfo($mockedProduct));
 }