commit 235bb3e9d0f49cfa924335ad6ffd39828203b76e Author: Francesco Placella Date: Mon May 25 01:52:49 2015 +0200 Fixed tests diff --git a/core/modules/content_translation/content_translation.install b/core/modules/content_translation/content_translation.install index b25d0b0..ea24954 100644 --- a/core/modules/content_translation/content_translation.install +++ b/core/modules/content_translation/content_translation.install @@ -18,7 +18,7 @@ function content_translation_install() { // Initialize the Content Translation form language type configuration. /** @var \Drupal\language\LanguageNegotiatorInterface $negotiator */ $negotiator = \Drupal::service('language_negotiator'); - $negotiator->updateConfiguration([ContentTranslationFormLanguage::TYPE]); + $negotiator->updateConfiguration([]); } /** diff --git a/core/modules/content_translation/content_translation.module b/core/modules/content_translation/content_translation.module index abc417d..b1d2018 100644 --- a/core/modules/content_translation/content_translation.module +++ b/core/modules/content_translation/content_translation.module @@ -77,7 +77,6 @@ function content_translation_module_implements_alter(&$implementations, $hook) { function content_translation_language_types_info() { return [ ContentTranslationFormLanguage::TYPE => array( - 'name' => t('Content Translation form language'), 'fixed' => [ContentTranslationFormLanguage::METHOD_ID], 'locked' => TRUE, ), diff --git a/core/modules/content_translation/src/Tests/ContentTranslationWorkflowsTest.php b/core/modules/content_translation/src/Tests/ContentTranslationWorkflowsTest.php index ec95891..935bc2a 100644 --- a/core/modules/content_translation/src/Tests/ContentTranslationWorkflowsTest.php +++ b/core/modules/content_translation/src/Tests/ContentTranslationWorkflowsTest.php @@ -160,10 +160,10 @@ protected function assertWorkflows(UserInterface $user, $expected_status) { // An editor should be pointed to the entity form in multilingual mode. // We need a new expected edit path with a new language. - $translate_url = $this->entity->urlInfo('drupal:content-translation-overview', ['language' => $languages[$this->langcodes[1]]]); - $translate_url->setAbsolute(FALSE); - $query = [ContentTranslationFormLanguage::QUERY_PARAMETER => $langcode, 'destination' => $translate_url->toString()]; - $options = ['query' => $query]; + $translate_url = $this->entity->url('drupal:content-translation-overview', ['language' => $languages[$this->langcodes[1]], 'absolute' => FALSE]); + debug($translate_url); + debug(Url::fromRoute('')->toString()); + $options = ['query' => [ContentTranslationFormLanguage::QUERY_PARAMETER => $langcode, 'destination' => $translate_url]]; $expected_edit_url = $this->entity->url('edit-form', $options); $this->assertUrl($expected_edit_url, [], 'The translation overview points to the edit form for editors when editing translations.'); } diff --git a/core/modules/simpletest/src/WebTestBase.php b/core/modules/simpletest/src/WebTestBase.php index 6ace8a8..25cdb56 100644 --- a/core/modules/simpletest/src/WebTestBase.php +++ b/core/modules/simpletest/src/WebTestBase.php @@ -2388,6 +2388,10 @@ protected function assertUrl($path, array $options = array(), $message = '', $gr // difference, decode them for comparison purposes. $actual_url = urldecode($this->getUrl()); $expected_url = urldecode($url); + if ($actual_url != $expected_url) { + debug($actual_url, 'actual'); + debug($expected_url, 'expected'); + } return $this->assertEqual($actual_url, $expected_url, $message, $group); }