Neos\FluidAdaptor\Tests\Unit\ViewHelpers\FormViewHelperTest::renderWithMethodGetAddsActionUriQueryAsHiddenFieldsWithHtmlescape PHP Method

renderWithMethodGetAddsActionUriQueryAsHiddenFieldsWithHtmlescape() public method

    public function renderWithMethodGetAddsActionUriQueryAsHiddenFieldsWithHtmlescape()
    {
        $viewHelper = $this->getAccessibleMock(\Neos\FluidAdaptor\ViewHelpers\FormViewHelper::class, array('renderChildren'), array(), '', false);
        $this->arguments['method'] = 'GET';
        $this->arguments['actionUri'] = 'http://localhost/fluid/test?foo=<bar>';
        $this->injectDependenciesIntoViewHelper($viewHelper);
        $this->securityContext->expects($this->any())->method('isInitialized')->will($this->returnValue(false));
        $viewHelper->expects($this->any())->method('renderChildren')->will($this->returnValue('formContent'));
        $this->viewHelperVariableContainerData = array(\Neos\FluidAdaptor\ViewHelpers\FormViewHelper::class => array('formFieldNames' => array()));
        $expectedResult = '<input type="hidden" name="foo" value="&lt;bar&gt;" />';
        $this->tagBuilder->expects($this->once())->method('setContent')->with($this->stringContains($expectedResult));
        $viewHelper->render('index');
    }
FormViewHelperTest