diff --git a/core/lib/Drupal/Core/Entity/DatabaseStorageControllerNG.php b/core/lib/Drupal/Core/Entity/DatabaseStorageControllerNG.php index 4ccf8da..a383924 100644 --- a/core/lib/Drupal/Core/Entity/DatabaseStorageControllerNG.php +++ b/core/lib/Drupal/Core/Entity/DatabaseStorageControllerNG.php @@ -96,7 +96,7 @@ public function __construct($entityType) { */ public function create(array $values) { // We have to determine the bundle first. - $bundle = $this->bundleKey ? $values[$this->bundleKey] : FALSE; + $bundle = $this->bundleKey && isset($values[$this->bundleKey]) ? $values[$this->bundleKey] : FALSE; $entity = new $this->entityClass(array(), $this->entityType, $bundle); // Set all other given values. diff --git a/core/modules/node/lib/Drupal/node/NodeStorageController.php b/core/modules/node/lib/Drupal/node/NodeStorageController.php index 5a0a3ae..69374a0 100644 --- a/core/modules/node/lib/Drupal/node/NodeStorageController.php +++ b/core/modules/node/lib/Drupal/node/NodeStorageController.php @@ -304,7 +304,7 @@ public function baseFieldDefinitions() { $properties['log'] = array( 'label' => t('Log'), 'description' => t('The log entry explaining the changes in this version.'), - 'type' => 'text_field', + 'type' => 'string_field', ); return $properties; } diff --git a/core/modules/system/lib/Drupal/system/Tests/Plugin/PluginTestBase.php b/core/modules/system/lib/Drupal/system/Tests/Plugin/PluginTestBase.php index c927f7e..7b8aa9a 100644 --- a/core/modules/system/lib/Drupal/system/Tests/Plugin/PluginTestBase.php +++ b/core/modules/system/lib/Drupal/system/Tests/Plugin/PluginTestBase.php @@ -89,7 +89,7 @@ public function setUp() { 'class' => 'Drupal\plugin_test\Plugin\plugin_test\mock_block\MockComplexContextBlock', 'context' => array( 'user' => array('class' => 'Drupal\user\Plugin\Core\Entity\User'), - 'node' => array('class' => 'Drupal\node\Plugin\Core\Entity\Node'), + 'node' => array('class' => 'Drupal\Core\Entity\EntityBCDecorator'), ), ), ); diff --git a/core/modules/system/tests/modules/plugin_test/lib/Drupal/plugin_test/Plugin/MockBlockManager.php b/core/modules/system/tests/modules/plugin_test/lib/Drupal/plugin_test/Plugin/MockBlockManager.php index 7e29259..157e583 100644 --- a/core/modules/system/tests/modules/plugin_test/lib/Drupal/plugin_test/Plugin/MockBlockManager.php +++ b/core/modules/system/tests/modules/plugin_test/lib/Drupal/plugin_test/Plugin/MockBlockManager.php @@ -91,7 +91,7 @@ public function __construct() { 'class' => 'Drupal\plugin_test\Plugin\plugin_test\mock_block\MockComplexContextBlock', 'context' => array( 'user' => array('class' => 'Drupal\user\Plugin\Core\Entity\User'), - 'node' => array('class' => 'Drupal\node\Plugin\Core\Entity\Node'), + 'node' => array('class' => 'Drupal\Core\Entity\EntityBCDecorator'), ), )); diff --git a/core/modules/views/lib/Drupal/views/Tests/DefaultViewsTest.php b/core/modules/views/lib/Drupal/views/Tests/DefaultViewsTest.php index 4a06511..c4f90b8 100644 --- a/core/modules/views/lib/Drupal/views/Tests/DefaultViewsTest.php +++ b/core/modules/views/lib/Drupal/views/Tests/DefaultViewsTest.php @@ -44,6 +44,9 @@ public static function getInfo() { protected function setUp() { parent::setUp(); + // Create Basic page node type. + $this->drupalCreateContentType(array('type' => 'page', 'name' => 'Basic page')); + $this->vocabulary = entity_create('taxonomy_vocabulary', array( 'name' => $this->randomName(), 'description' => $this->randomName(),