function ViewExecutableFactoryTest::setUp

Same name in other branches
  1. 9 core/modules/views/tests/src/Unit/ViewExecutableFactoryTest.php \Drupal\Tests\views\Unit\ViewExecutableFactoryTest::setUp()
  2. 10 core/modules/views/tests/src/Unit/ViewExecutableFactoryTest.php \Drupal\Tests\views\Unit\ViewExecutableFactoryTest::setUp()
  3. 11.x core/modules/views/tests/src/Unit/ViewExecutableFactoryTest.php \Drupal\Tests\views\Unit\ViewExecutableFactoryTest::setUp()

Overrides UnitTestCase::setUp

File

core/modules/views/tests/src/Unit/ViewExecutableFactoryTest.php, line 61

Class

ViewExecutableFactoryTest
@coversDefaultClass \Drupal\views\ViewExecutableFactory @group views

Namespace

Drupal\Tests\views\Unit

Code

protected function setUp() {
    parent::setUp();
    $this->user = $this->createMock('Drupal\\Core\\Session\\AccountInterface');
    $this->requestStack = new RequestStack();
    $this->view = $this->createMock('Drupal\\views\\ViewEntityInterface');
    $this->viewsData = $this->getMockBuilder('Drupal\\views\\ViewsData')
        ->disableOriginalConstructor()
        ->getMock();
    $this->routeProvider = $this->createMock('Drupal\\Core\\Routing\\RouteProviderInterface');
    $this->viewExecutableFactory = new ViewExecutableFactory($this->user, $this->requestStack, $this->viewsData, $this->routeProvider);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.