EntityReferenceHandlerSettingUpdateTest.php in Zircon Profile 8
File
core/modules/field/src/Tests/Update/EntityReferenceHandlerSettingUpdateTest.php
View source
<?php
namespace Drupal\field\Tests\Update;
use Drupal\system\Tests\Update\UpdatePathTestBase;
class EntityReferenceHandlerSettingUpdateTest extends UpdatePathTestBase {
protected function setDatabaseDumpFiles() {
$this->databaseDumpFiles = [
__DIR__ . '/../../../../system/tests/fixtures/update/drupal-8.bare.standard.php.gz',
];
}
public function testFieldPostUpdateERHandlerSetting() {
$configFactory = $this->container
->get('config.factory');
$config = $configFactory
->get('field.field.node.article.field_image');
$settings = $config
->get('settings');
$this
->assertEqual($settings['handler'], 'default:node');
$this
->runUpdates();
$config = $configFactory
->get('field.field.node.article.field_image');
$settings = $config
->get('settings');
$this
->assertEqual($settings['handler'], 'default:file');
}
}