Exemplo n.º 1
0
 /**
  * Run test execute method (fail generate label)
  */
 public function testExecuteLabelGenerateFail()
 {
     $this->shipmentLoaderMock->expects($this->once())->method('load')->will($this->returnValue($this->shipmentMock));
     $this->labelGenerator->expects($this->once())->method('create')->with($this->shipmentMock, $this->requestMock)->will($this->throwException(new \Magento\Framework\Model\Exception()));
     $this->responseMock->expects($this->once())->method('representJson');
     $this->assertNull($this->controller->execute());
 }