diff --git a/modules/node/node.install b/modules/node/node.install index 852c1117b11e4e04fd650b1eb7c18b8ece73e039..a08e997570602b5dd3874318aa6488d0912c97a0 100644 --- a/modules/node/node.install +++ b/modules/node/node.install @@ -628,6 +628,8 @@ function node_update_7006(&$sandbox) { 'entity_type' => 'node', 'bundle' => $node_type->type, 'label' => $node_type->body_label, + 'description' => isset($node_type->description) ? $node_type->description : '', + 'required' => (isset($node_type->min_word_count) && $node_type->min_word_count > 0) ? 1 : 0, 'widget' => array( 'type' => 'text_textarea_with_summary', 'settings' => array( diff --git a/modules/simpletest/tests/upgrade/upgrade.node.test b/modules/simpletest/tests/upgrade/upgrade.node.test index 163dbef5e9db58a71ae0c3aa057b29639ccffa7e..cd44790c72883ca4b0bd66ba1b47b14c68f7c8b9 100644 --- a/modules/simpletest/tests/upgrade/upgrade.node.test +++ b/modules/simpletest/tests/upgrade/upgrade.node.test @@ -27,6 +27,11 @@ class NodeBodyUpgradePathTestCase extends UpgradePathTestCase { */ public function testNodeBodyUpgrade() { $this->assertTrue($this->performUpgrade(), t('The upgrade was completed successfully.')); + + $instance = field_info_instance('node', 'body', 'story'); + $this->assertIdentical($instance['required'], 0, 'The required setting was preserved during the upgrade path.'); + $this->assertTrue($instance['description'], 'The description was preserved during the upgrade path'); + $this->drupalGet("content/1263769200"); $this->assertText('node body (broken) - 37');