function SqlQueryTest::viewsData

Same name in other branches
  1. 9 core/modules/views/tests/src/Kernel/Plugin/SqlQueryTest.php \Drupal\Tests\views\Kernel\Plugin\SqlQueryTest::viewsData()
  2. 8.9.x core/modules/views/tests/src/Kernel/Plugin/SqlQueryTest.php \Drupal\Tests\views\Kernel\Plugin\SqlQueryTest::viewsData()
  3. 11.x core/modules/views/tests/src/Kernel/Plugin/SqlQueryTest.php \Drupal\Tests\views\Kernel\Plugin\SqlQueryTest::viewsData()

Overrides ViewsKernelTestBase::viewsData

File

core/modules/views/tests/src/Kernel/Plugin/SqlQueryTest.php, line 29

Class

SqlQueryTest
Tests the sql query plugin.

Namespace

Drupal\Tests\views\Kernel\Plugin

Code

protected function viewsData() {
    $data = parent::viewsData();
    $data['views_test_data']['table']['base']['access query tag'] = 'test_tag';
    $data['views_test_data']['table']['base']['query metadata'] = [
        'key1' => 'test_metadata',
        'key2' => 'test_metadata2',
    ];
    return $data;
}

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