Esempio n. 1
0
 /**
  * @param $priceType
  * @param $priceValue
  * @param $priceValueType
  * @param $price
  * @param $expectedPrice
  * @dataProvider calculateProductPriceProvider
  */
 public function testCalculatePrice($priceType, $priceValue, $priceValueType, $price, $expectedPrice)
 {
     $this->_object = new Public_Xcom_Listing_Model_Listing();
     $this->_object->setData('price_type', $priceType);
     $this->_object->setData('price_value', $priceValue);
     $this->_object->setData('price_value_type', $priceValueType);
     $this->_productOne->setPrice($price);
     $actualPrice = $this->_object->calculatePrice($this->_productOne);
     $this->assertEquals($expectedPrice, $actualPrice);
 }