示例#1
0
 /**
  * Test getShippingRate method
  */
 public function testGetShippingRate()
 {
     $rate = $this->getMock('Magento\\Quote\\Model\\Quote\\Address\\Rate', ['__wakeup'], [], '', false);
     $this->shippingAddress->setShippingMethod(self::SHIPPING_METHOD);
     $this->shippingAddress->expects($this->once())->method('getShippingRateByCode')->with(self::SHIPPING_METHOD)->will($this->returnValue($rate));
     $this->assertEquals($rate, $this->model->getShippingRate());
 }
示例#2
0
 public function testGetShippingPriceExclTax()
 {
     $this->_prepareTestGetShippingPrice(false);
     $this->assertEquals(self::SHIPPING_PRICE_FORMATTED, $this->model->getShippingPriceExclTax());
 }