function ConnectionUnitTest::getQuery

Same name in this branch
  1. 10 core/modules/mysql/tests/src/Kernel/mysql/ConnectionUnitTest.php \Drupal\Tests\mysql\Kernel\mysql\ConnectionUnitTest::getQuery()
Same name in other branches
  1. 9 core/modules/mysql/tests/src/Kernel/mysql/ConnectionUnitTest.php \Drupal\Tests\mysql\Kernel\mysql\ConnectionUnitTest::getQuery()
  2. 9 core/modules/pgsql/tests/src/Kernel/pgsql/ConnectionUnitTest.php \Drupal\Tests\pgsql\Kernel\pgsql\ConnectionUnitTest::getQuery()
  3. 11.x core/modules/mysql/tests/src/Kernel/mysql/ConnectionUnitTest.php \Drupal\Tests\mysql\Kernel\mysql\ConnectionUnitTest::getQuery()
  4. 11.x core/modules/pgsql/tests/src/Kernel/pgsql/ConnectionUnitTest.php \Drupal\Tests\pgsql\Kernel\pgsql\ConnectionUnitTest::getQuery()

Returns a set of queries specific for PostgreSQL.

Overrides DriverSpecificConnectionUnitTestBase::getQuery

File

core/modules/pgsql/tests/src/Kernel/pgsql/ConnectionUnitTest.php, line 19

Class

ConnectionUnitTest
PostgreSQL-specific connection unit tests.

Namespace

Drupal\Tests\pgsql\Kernel\pgsql

Code

protected function getQuery() : array {
    return [
        'connection_id' => 'SELECT pg_backend_pid()',
        'processlist' => 'SELECT pid FROM pg_stat_activity',
        'show_tables' => 'SELECT * FROM pg_catalog.pg_tables',
    ];
}

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