/** * @covers Mage_Adminhtml_Block_Catalog_Product_Edit_NewCategory::getSaveCategoryUrl * @covers Mage_Adminhtml_Block_Catalog_Product_Edit_NewCategory::getSuggestCategoryUrl * @dataProvider urlMethodsDataProvider * @param string $expectedUrl * @param string $executedMethod */ public function testGetUrlMethods($expectedUrl, $executedMethod) { $this->_urlModel->expects($this->once())->method('getUrl')->with($expectedUrl)->will($this->returnCallback(function ($string) { return strrev($string); })); $this->assertEquals(strrev($expectedUrl), call_user_func_array(array($this->_object, $executedMethod), array($expectedUrl))); }