diff --git a/core/modules/config/tests/config_test/config_test.info b/core/modules/config/tests/config_test/config_test.info index aceba11..3c0ca6b 100644 --- a/core/modules/config/tests/config_test/config_test.info +++ b/core/modules/config/tests/config_test/config_test.info @@ -2,4 +2,4 @@ name = Configuration test module package = Core version = VERSION core = 8.x -hidden = FALSE +hidden = TRUE diff --git a/core/modules/config/tests/config_test/config_test.module b/core/modules/config/tests/config_test/config_test.module index 4a06695..e77b999 100644 --- a/core/modules/config/tests/config_test/config_test.module +++ b/core/modules/config/tests/config_test/config_test.module @@ -57,24 +57,6 @@ function config_test_config_import_change($name, $new_config, $old_config) { } /** - * Implements hook_config_import_delete(). - */ -function config_test_config_import_delete($name, $new_config, $old_config) { - if (strpos($name, 'config_test.dynamic.') !== 0) { - return FALSE; - } - // Set a global value we can check in test code. - $GLOBALS['hook_config_import'] = __FUNCTION__; - - // @todo Make this less ugly. - list($entity_type) = explode('.', $name); - $entity_info = entity_get_info($entity_type); - $id = substr($name, strlen($entity_info['config prefix']) + 1); - config_test_delete($id); - return TRUE; -} - -/** * Implements hook_entity_info(). */ function config_test_entity_info() { @@ -180,7 +162,6 @@ function config_test_list_page() { * Menu callback: displays the 'Add new config_test' form. */ function config_test_add() { - drupal_set_title(t('Create a config_test')); $entity = entity_create('config_test', array()); return entity_get_form($entity); } @@ -189,7 +170,7 @@ function config_test_add() { * Menu callback: displays the 'Edit existing config_test form. */ function config_test_edit($entity) { - drupal_set_title(t('config_test @id', array('@id' => $entity->id)), PASS_THROUGH); + drupal_set_title(t('config_test @id', array('@id' => $entity->label)), PASS_THROUGH); return entity_get_form($entity); } diff --git a/core/modules/config/tests/config_test/lib/Drupal/config_test/ConfigTestFormController.php b/core/modules/config/tests/config_test/lib/Drupal/config_test/ConfigTestFormController.php index ed8a2e4..a7e5830 100644 --- a/core/modules/config/tests/config_test/lib/Drupal/config_test/ConfigTestFormController.php +++ b/core/modules/config/tests/config_test/lib/Drupal/config_test/ConfigTestFormController.php @@ -76,7 +76,7 @@ public function save(array $form, array &$form_state) { $is_new = $entity->isNew(); $entity->save(); - $message = $is_new ? t('config_test @id has been created.', array('@id' => $entity->id())) : t('config_test @id has been updated.', array('@id' => $entity->id())); + $message = $is_new ? t('config_test @label has been created.', array('@label' => $entity->label())) : t('config_test @label has been updated.', array('@label' => $entity->label())); drupal_set_message($message); if ($entity->id()) { @@ -95,7 +95,7 @@ public function save(array $form, array &$form_state) { public function delete(array $form, array &$form_state) { $entity = $this->getEntity($form_state); $entity->delete(); - drupal_set_message(t('config_test @id has been deleted.', array('@id' => $entity->id()))); + drupal_set_message(t('config_test @label has been deleted.', array('@label' => $entity->label()))); $form_state['redirect'] = 'admin/structure/config_test/manage'; } };