function EntityQueryTest::assertResult

Same name in other branches
  1. 9 core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php \Drupal\KernelTests\Core\Entity\EntityQueryTest::assertResult()
  2. 8.9.x core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php \Drupal\KernelTests\Core\Entity\EntityQueryTest::assertResult()
  3. 10 core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php \Drupal\KernelTests\Core\Entity\EntityQueryTest::assertResult()

@internal

6 calls to EntityQueryTest::assertResult()
EntityQueryTest::testAlterHook in core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php
Test the entity query alter hooks are invoked.
EntityQueryTest::testDelta in core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php
Tests queries with delta conditions.
EntityQueryTest::testEntityQuery in core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php
Tests basic functionality.
EntityQueryTest::testNestedConditionGroups in core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php
Tests that nested condition groups work as expected.
EntityQueryTest::testSort in core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php
Tests sort().

... See full list

File

core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php, line 747

Class

EntityQueryTest
Tests Entity Query functionality.

Namespace

Drupal\KernelTests\Core\Entity

Code

protected function assertResult() : void {
    $assert = [];
    $expected = func_get_args();
    if ($expected && is_array($expected[0])) {
        $expected = $expected[0];
    }
    foreach ($expected as $binary) {
        $assert[$binary] = strval($binary);
    }
    $this->assertSame($assert, $this->queryResults);
}

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