You are here

public function EntityRevisionsTest::testRevisions in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/system/tests/src/Functional/Entity/EntityRevisionsTest.php \Drupal\Tests\system\Functional\Entity\EntityRevisionsTest::testRevisions()
  2. 9 core/modules/system/tests/src/Functional/Entity/EntityRevisionsTest.php \Drupal\Tests\system\Functional\Entity\EntityRevisionsTest::testRevisions()

Check node revision related operations.

File

core/modules/system/tests/src/Functional/Entity/EntityRevisionsTest.php, line 56

Class

EntityRevisionsTest
Create a entity with revisions and test viewing, saving, reverting, and deleting revisions.

Namespace

Drupal\Tests\system\Functional\Entity

Code

public function testRevisions() {

  // All revisable entity variations have to have the same results.
  foreach (entity_test_entity_types(ENTITY_TEST_TYPES_REVISABLE) as $entity_type) {
    $this
      ->runRevisionsTests($entity_type);
  }
}