You are here

function EmptyStatementTest::testEmptyFetchAll in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 core/tests/Drupal/Tests/Core/Database/EmptyStatementTest.php \Drupal\Tests\Core\Database\EmptyStatementTest::testEmptyFetchAll()

Tests that the empty result set mass-fetches in an expected way.

File

core/tests/Drupal/Tests/Core/Database/EmptyStatementTest.php, line 41
Contains \Drupal\Tests\Core\Database\EmptyStatementTest.

Class

EmptyStatementTest
Tests the empty pseudo-statement class.

Namespace

Drupal\Tests\Core\Database

Code

function testEmptyFetchAll() {
  $result = new StatementEmpty();
  $this
    ->assertEquals($result
    ->fetchAll(), array(), 'Empty array returned from empty result set.');
}