You are here

protected function ViewKernelTestBase::setUp in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/views/src/Tests/ViewKernelTestBase.php \Drupal\views\Tests\ViewKernelTestBase::setUp()

Parameters

bool $import_test_views: Should the views specififed on the test class be imported. If you need to setup some additional stuff, like fields, you need to call false and then call createTestViews for your own.

Overrides KernelTestBase::setUp

37 calls to ViewKernelTestBase::setUp()
AreaEntityTest::setUp in core/modules/views/src/Tests/Handler/AreaEntityTest.php
Performs setup tasks before each individual test method is run.
AreaTextTest::setUp in core/modules/views/src/Tests/Handler/AreaTextTest.php
Performs setup tasks before each individual test method is run.
CacheTest::setUp in core/modules/views/src/Tests/Plugin/CacheTest.php
Performs setup tasks before each individual test method is run.
CommentUserNameTest::setUp in core/modules/comment/src/Tests/Views/CommentUserNameTest.php
Performs setup tasks before each individual test method is run.
CommentViewKernelTestBase::setUp in core/modules/comment/src/Tests/Views/CommentViewKernelTestBase.php
Performs setup tasks before each individual test method is run.

... See full list

37 methods override ViewKernelTestBase::setUp()
AreaEntityTest::setUp in core/modules/views/src/Tests/Handler/AreaEntityTest.php
Performs setup tasks before each individual test method is run.
AreaTextTest::setUp in core/modules/views/src/Tests/Handler/AreaTextTest.php
Performs setup tasks before each individual test method is run.
CacheTest::setUp in core/modules/views/src/Tests/Plugin/CacheTest.php
Performs setup tasks before each individual test method is run.
CommentUserNameTest::setUp in core/modules/comment/src/Tests/Views/CommentUserNameTest.php
Performs setup tasks before each individual test method is run.
CommentViewKernelTestBase::setUp in core/modules/comment/src/Tests/Views/CommentViewKernelTestBase.php
Performs setup tasks before each individual test method is run.

... See full list

File

core/modules/views/src/Tests/ViewKernelTestBase.php, line 42
Contains \Drupal\views\Tests\ViewKernelTestBase.

Class

ViewKernelTestBase
Defines a base class for Views unit testing.

Namespace

Drupal\views\Tests

Code

protected function setUp($import_test_views = TRUE) {
  parent::setUp();
  $this
    ->installSchema('system', array(
    'router',
    'sequences',
  ));
  $this
    ->setUpFixtures();
  if ($import_test_views) {
    ViewTestData::createTestViews(get_class($this), array(
      'views_test_config',
    ));
  }
}