Neos\Flow\Tests\Unit\Mvc\View\AbstractViewTest::assignCanOverridePreviouslyAssignedValues PHP Метод

assignCanOverridePreviouslyAssignedValues() публичный Метод

    public function assignCanOverridePreviouslyAssignedValues()
    {
        $view = $this->getAccessibleMock(Mvc\View\AbstractView::class, ['setControllerContext', 'render']);
        $view->assign('foo', 'FooValue');
        $view->assign('foo', 'FooValueOverridden');
        $expectedResult = ['foo' => 'FooValueOverridden'];
        $actualResult = $view->_get('variables');
        $this->assertEquals($expectedResult, $actualResult);
    }