function SqlContentEntityStorageTest::testGetDataTable

Tests SqlContentEntityStorage::getDataTable().

@legacy-covers ::__construct @legacy-covers ::getDataTable

File

core/tests/Drupal/Tests/Core/Entity/Sql/SqlContentEntityStorageTest.php, line 243

Class

SqlContentEntityStorageTest
Tests Drupal\Core\Entity\Sql\SqlContentEntityStorage.

Namespace

Drupal\Tests\Core\Entity\Sql

Code

public function testGetDataTable() : void {
  $this->entityType
    ->expects($this->any())
    ->method('isTranslatable')
    ->willReturn(TRUE);
  $this->entityType
    ->expects($this->exactly(1))
    ->method('getDataTable')
    ->willReturn('entity_test_field_data');
  $this->entityType
    ->expects($this->any())
    ->method('getRevisionMetadataKeys')
    ->willReturn([]);
  $this->setUpEntityStorage();
  $this->assertSame('entity_test_field_data', $this->entityStorage
    ->getDataTable());
}

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