/** * @dataProvider aroundValidateDataProvider * * @param $typeId * @param $expectedResult */ public function testAroundValidate($typeId, $expectedResult) { $this->productMock->expects($this->any())->method('getTypeId')->will($this->returnValue($typeId)); $result = $this->priceBackendPlugin->aroundValidate($this->priceAttributeMock, $this->closure, $this->productMock); $this->assertEquals($expectedResult, $result); }
/** * @dataProvider aroundValidateDataProvider * * @param $typeId * @param $expectedResult */ public function testAroundValidate($typeId, $expectedResult) { $this->product->expects(static::once())->method('getTypeId')->willReturn($typeId); $result = $this->priceBackendPlugin->aroundValidate($this->priceAttribute, $this->closure, $this->product); $this->assertEquals($expectedResult, $result); }