Ejemplo n.º 1
0
 public function testGetRefreshPathUrl()
 {
     $url = 'some/magento/refresh/path/url';
     $params = ['argument' => 'value'];
     $this->urlBuilderMock->expects($this->once())->method('getUrl')->with('catalog/*/refreshPath', ['_current' => true, '_query' => ['isAjax' => null], 'argument' => 'value'])->willReturn($url);
     $this->assertEquals($url, $this->form->getRefreshPathUrl($params));
 }
Ejemplo n.º 2
0
 /**
  * Run test getCategoryId method
  *
  * @return int
  */
 public function testGetCategoryId()
 {
     $this->requestMock->expects($this->once())->method('getParam')->with('id')->will($this->returnValue(789));
     $this->assertEquals(789, $this->form->getCategoryId());
 }