You are here

public function EntityTest::testResolveMismatchEntityLoad in GraphQL 8.4

@covers \Drupal\graphql\Plugin\GraphQL\DataProducer\Entity\EntityLoad::resolve

File

tests/src/Kernel/DataProducer/EntityTest.php, line 343

Class

EntityTest
Data producers Entity test class.

Namespace

Drupal\Tests\graphql\Kernel\DataProducer

Code

public function testResolveMismatchEntityLoad() : void {
  $result = $this
    ->executeDataProducer('entity_load', [
    'type' => $this->node
      ->getEntityTypeId(),
    'id' => $this->node
      ->id(),
    'bundles' => [
      'otherbundle',
    ],
  ]);

  // @todo Add metadata check.
  // $this->assertContains('node:1', $metadata->getCacheTags());
  $this
    ->assertNull($result);
}