public function EntityDecoupledTranslationRevisionsTest::testInternalProperties in Drupal 8
Same name and namespace in other branches
- 9 core/tests/Drupal/KernelTests/Core/Entity/EntityDecoupledTranslationRevisionsTest.php \Drupal\KernelTests\Core\Entity\EntityDecoupledTranslationRevisionsTest::testInternalProperties()
Tests that internal properties are preserved while creating a new revision.
File
- core/
tests/ Drupal/ KernelTests/ Core/ Entity/ EntityDecoupledTranslationRevisionsTest.php, line 528
Class
- EntityDecoupledTranslationRevisionsTest
- Test decoupled translation revisions.
Namespace
Drupal\KernelTests\Core\EntityCode
public function testInternalProperties() {
$entity = EntityTestMulRev::create();
$this
->doTestInternalProperties($entity);
$entity = EntityTestMulRev::create();
$entity
->save();
$this
->doTestInternalProperties($entity);
/** @var \Drupal\entity_test\Entity\EntityTestMulRev $translation */
$translation = EntityTestMulRev::create()
->addTranslation('it');
$translation
->save();
$this
->doTestInternalProperties($translation);
}