/** * Checks if withRoute() accepts null and passes that value * to the url helper. */ public function testNullIsAcceptedAsRoute() { $this->url->withRoute(null); (string) $this->url; $params = $this->getParamsOfLastHelperCall(); $this->assertNull($params['name']); }
/** * Returns a url object that may be parametrized further and that * is automatically converted to a url string when it is printed. * * @param string $action * @param string $controller * @param string $module * @return Mol_View_Helper_Value_Url */ public function to($action, $controller, $module = 'default') { $url = new Mol_View_Helper_Value_Url($this->view); $url->withParam('action', $action); $url->withParam('controller', $controller); $url->withParam('module', $module); $url->withRoute('default'); return $url; }