示例#1
0
 /**
  * {@inheritdoc}
  */
 protected function setUp()
 {
     $this->quoteProductFormatter = $this->getMockBuilder('OroB2B\\Bundle\\SaleBundle\\Formatter\\QuoteProductFormatter')->disableOriginalConstructor()->getMock();
     $this->quoteProductFormatter->expects($this->any())->method('formatTypeLabels')->will($this->returnCallback(function (array $types) {
         return $types;
     }));
     $this->quoteProductOfferFormatter = $this->getMockBuilder('OroB2B\\Bundle\\SaleBundle\\Formatter\\QuoteProductOfferFormatter')->disableOriginalConstructor()->getMock();
     $this->quoteProductOfferFormatter->expects($this->any())->method('formatPriceTypeLabels')->will($this->returnCallback(function (array $types) {
         return $types;
     }));
     parent::setUp();
 }
 public function testFormatProductRequest()
 {
     $this->quoteProductFormatter->expects($this->once())->method('formatRequest')->with(new QuoteProductRequest());
     $this->extension->formatProductRequest(new QuoteProductRequest());
 }