public function setUp() { $this->form = $this->getMock('Symfony\\Component\\Form\\Test\\FormInterface'); $this->formFactory = $this->getMock('Symfony\\Component\\Form\\FormFactoryInterface'); $this->formFactory->expects($this->any())->method('create')->will($this->returnValue($this->form)); $this->filterUtility = $this->getMockBuilder('Oro\\Bundle\\FilterBundle\\Filter\\FilterUtility')->disableOriginalConstructor()->getMock(); $this->filterUtility->expects($this->any())->method('getExcludeParams')->willReturn([]); $this->formatter = $this->getMockBuilder('OroB2B\\Bundle\\ProductBundle\\Formatter\\ProductUnitLabelFormatter')->disableOriginalConstructor()->getMock(); $this->productPriceFilter = new ProductPriceFilter($this->formFactory, $this->filterUtility, $this->formatter); }