public function ContentTranslationEntityBundleInfoTest::testFieldSynchronizationWithDisabledBundle in Drupal 9
Same name and namespace in other branches
- 8 core/modules/content_translation/tests/src/Kernel/ContentTranslationEntityBundleInfoTest.php \Drupal\Tests\content_translation\Kernel\ContentTranslationEntityBundleInfoTest::testFieldSynchronizationWithDisabledBundle()
- 10 core/modules/content_translation/tests/src/Kernel/ContentTranslationEntityBundleInfoTest.php \Drupal\Tests\content_translation\Kernel\ContentTranslationEntityBundleInfoTest::testFieldSynchronizationWithDisabledBundle()
Tests that field synchronization is skipped for disabled bundles.
File
- core/
modules/ content_translation/ tests/ src/ Kernel/ ContentTranslationEntityBundleInfoTest.php, line 89
Class
- ContentTranslationEntityBundleInfoTest
- Tests the Content Translation bundle info logic.
Namespace
Drupal\Tests\content_translation\KernelCode
public function testFieldSynchronizationWithDisabledBundle() {
$entity = EntityTestMul::create();
$entity
->save();
/** @var \Drupal\Core\Entity\ContentEntityInterface $translation */
$translation = $entity
->addTranslation('it');
$translation
->save();
$this
->assertTrue($entity
->isTranslatable());
}