function ContentTranslationFieldSyncRevisionTest::testChangeDefaultLanguageNonTranslatableFieldsHidden
Same name in other branches
- 9 core/modules/content_translation/tests/src/Kernel/ContentTranslationFieldSyncRevisionTest.php \Drupal\Tests\content_translation\Kernel\ContentTranslationFieldSyncRevisionTest::testChangeDefaultLanguageNonTranslatableFieldsHidden()
- 8.9.x core/modules/content_translation/tests/src/Kernel/ContentTranslationFieldSyncRevisionTest.php \Drupal\Tests\content_translation\Kernel\ContentTranslationFieldSyncRevisionTest::testChangeDefaultLanguageNonTranslatableFieldsHidden()
- 11.x core/modules/content_translation/tests/src/Kernel/ContentTranslationFieldSyncRevisionTest.php \Drupal\Tests\content_translation\Kernel\ContentTranslationFieldSyncRevisionTest::testChangeDefaultLanguageNonTranslatableFieldsHidden()
Tests changing the default language of an entity.
File
-
core/
modules/ content_translation/ tests/ src/ Kernel/ ContentTranslationFieldSyncRevisionTest.php, line 459
Class
- ContentTranslationFieldSyncRevisionTest
- Tests the field synchronization logic when revisions are involved.
Namespace
Drupal\Tests\content_translation\KernelCode
public function testChangeDefaultLanguageNonTranslatableFieldsHidden() : void {
$this->setUntranslatableFieldWidgetsDisplay(FALSE);
$entity = $this->saveNewEntity();
$entity->langcode = 'it';
$this->assertCount(0, $entity->validate());
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.