diff -u b/core/lib/Drupal/Core/Config/ConfigInstaller.php b/core/lib/Drupal/Core/Config/ConfigInstaller.php --- b/core/lib/Drupal/Core/Config/ConfigInstaller.php +++ b/core/lib/Drupal/Core/Config/ConfigInstaller.php @@ -115,13 +115,11 @@ $old_state = $this->configFactory->getOverrideState(); $this->configFactory->setOverrideState(FALSE); + // Only import new config. However allow updates of config that is going - // to be updated as a result of a secondary write. - foreach ($sorted_config as $name) { - if ($this->activeStorage->exists($name)) { - unset($sorted_config[$name]); - } - } + // to be updated as a result of a secondary write so remove existing + // configuration before saving any new configuration. + $sorted_config = array_diff($sorted_config, $this->activeStorage->listAll()); foreach ($sorted_config as $name) { $new_config = new Config($name, $this->activeStorage, $this->eventDispatcher, $this->typedConfig); only in patch2: unchanged: --- a/core/modules/system/lib/Drupal/system/Tests/Entity/EntityCrudHookTest.php +++ b/core/modules/system/lib/Drupal/system/Tests/Entity/EntityCrudHookTest.php @@ -133,6 +133,10 @@ public function testBlockHooks() { public function testCommentHooks() { $account = $this->createUser(); $this->enableModules(array('entity', 'filter')); + entity_create('node_type', array( + 'type' => 'article', + 'name' => 'Article', + ))->save(); $this->container->get('comment.manager')->addDefaultField('node', 'article', 'comment', COMMENT_OPEN); $node = entity_create('node', array( only in patch2: unchanged: --- a/core/modules/tracker/lib/Drupal/tracker/Tests/TrackerNodeAccessTest.php +++ b/core/modules/tracker/lib/Drupal/tracker/Tests/TrackerNodeAccessTest.php @@ -32,6 +32,7 @@ public static function getInfo() { public function setUp() { parent::setUp(); node_access_rebuild(); + $this->drupalCreateContentType(array('type' => 'page')); $this->container->get('comment.manager')->addDefaultField('node', 'page', 'comment', COMMENT_OPEN); \Drupal::state()->set('node_access_test.private', TRUE); } only in patch2: unchanged: --- a/core/modules/views/lib/Drupal/views/Tests/Entity/FieldEntityTest.php +++ b/core/modules/views/lib/Drupal/views/Tests/Entity/FieldEntityTest.php @@ -45,6 +45,7 @@ public function testGetEntity() { $account = entity_create('user', array('name' => $this->randomName(), 'bundle' => 'user')); $account->save(); + $this->drupalCreateContentType(array('type' => 'page')); $this->container->get('comment.manager')->addDefaultField('node', 'page'); // Force a flush of the in-memory storage. $this->container->get('views.views_data')->clear(); only in patch2: unchanged: --- a/core/modules/views/lib/Drupal/views/Tests/Handler/HandlerAllTest.php +++ b/core/modules/views/lib/Drupal/views/Tests/Handler/HandlerAllTest.php @@ -53,6 +53,7 @@ public static function getInfo() { * Tests most of the handlers. */ public function testHandlers() { + $this->drupalCreateContentType(array('type' => 'article')); $this->container->get('comment.manager')->addDefaultField('node', 'article'); $object_types = array_keys(ViewExecutable::viewsHandlerTypes()); only in patch2: unchanged: --- a/core/modules/views/lib/Drupal/views/Tests/Handler/HandlerTest.php +++ b/core/modules/views/lib/Drupal/views/Tests/Handler/HandlerTest.php @@ -41,6 +41,7 @@ public static function getInfo() { protected function setUp() { parent::setUp(); + $this->drupalCreateContentType(array('type' => 'page')); $this->container->get('comment.manager')->addDefaultField('node', 'page'); $this->enableViewsTestModule(); } only in patch2: unchanged: --- a/core/modules/views/lib/Drupal/views/Tests/ViewExecutableTest.php +++ b/core/modules/views/lib/Drupal/views/Tests/ViewExecutableTest.php @@ -88,6 +88,10 @@ protected function setUpFixtures() { $this->installSchema('node', array('node', 'node_field_data')); $this->installSchema('comment', array('comment', 'comment_entity_statistics')); $this->installConfig(array('field')); + entity_create('node_type', array( + 'type' => 'page', + 'name' => 'Page', + ))->save(); $this->container->get('comment.manager')->addDefaultField('node', 'page'); parent::setUpFixtures();