protected function ConfigEntityImportTest::doBlockUpdate in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/system/src/Tests/Entity/ConfigEntityImportTest.php \Drupal\system\Tests\Entity\ConfigEntityImportTest::doBlockUpdate()
Tests updating a block during import.
1 call to ConfigEntityImportTest::doBlockUpdate()
- ConfigEntityImportTest::testConfigUpdateImport in core/
modules/ system/ src/ Tests/ Entity/ ConfigEntityImportTest.php - Runs test methods for each module within a single test run.
File
- core/
modules/ system/ src/ Tests/ Entity/ ConfigEntityImportTest.php, line 71 - Contains \Drupal\system\Tests\Entity\ConfigEntityImportTest.
Class
- ConfigEntityImportTest
- Tests ConfigEntity importing.
Namespace
Drupal\system\Tests\EntityCode
protected function doBlockUpdate() {
// Create a test block with a known label.
$name = 'block.block.apple';
$block = $this
->drupalPlaceBlock('system_powered_by_block', array(
'id' => 'apple',
'label' => 'Red Delicious',
));
$this
->checkSinglePluginConfigSync($block, 'settings', 'label', 'Red Delicious');
// Read the existing data, and prepare an altered version in sync.
$custom_data = $original_data = $this->container
->get('config.storage')
->read($name);
$custom_data['settings']['label'] = 'Granny Smith';
$this
->assertConfigUpdateImport($name, $original_data, $custom_data);
}