LanguageSelectWidgetUpdateTest.php in Drupal 8
File
core/modules/language/tests/src/Functional/Update/LanguageSelectWidgetUpdateTest.php
View source
<?php
namespace Drupal\Tests\language\Functional\Update;
use Drupal\Core\Entity\Entity\EntityFormDisplay;
use Drupal\FunctionalTests\Update\UpdatePathTestBase;
class LanguageSelectWidgetUpdateTest extends UpdatePathTestBase {
protected function setDatabaseDumpFiles() {
$this->databaseDumpFiles = [
__DIR__ . '/../../../../../system/tests/fixtures/update/drupal-8.filled.standard.php.gz',
];
}
public function testLanguagePostUpdateLanguageSelectWidget() {
$content_before = EntityFormDisplay::load('node.page.default')
->get('content');
$this
->assertEqual([], $content_before['langcode']['settings']);
$this
->runUpdates();
$content_after = EntityFormDisplay::load('node.page.default')
->get('content');
$this
->assertEqual([
'include_locked' => TRUE,
], $content_after['langcode']['settings']);
}
}