diff --git a/core/modules/language/src/Tests/LanguageSwitchingTest.php b/core/modules/language/src/Tests/LanguageSwitchingTest.php index 1c39a88..81c31ec 100644 --- a/core/modules/language/src/Tests/LanguageSwitchingTest.php +++ b/core/modules/language/src/Tests/LanguageSwitchingTest.php @@ -86,7 +86,6 @@ protected function doTestLanguageBlockAuthenticated($block_label) { list($langcode) = array_intersect($classes, array('en', 'fr')); $list_items[] = array( 'langcode_class' => $langcode, - 'data-drupal-link-system-path' => (string) $list_item['data-drupal-link-system-path'], ); $anchors[] = array( 'hreflang' => (string) $list_item->a['hreflang'], @@ -95,8 +94,8 @@ protected function doTestLanguageBlockAuthenticated($block_label) { $labels[] = (string) $list_item->a; } $expected_list_items = array( - 0 => array('langcode_class' => 'en', 'data-drupal-link-system-path' => 'user/2'), - 1 => array('langcode_class' => 'fr', 'data-drupal-link-system-path' => 'user/2'), + 0 => array('langcode_class' => 'en'), + 1 => array('langcode_class' => 'fr'), ); $this->assertIdentical($list_items, $expected_list_items, 'The list items have the correct attributes that will allow the drupal.active-link library to mark them as active.'); $expected_anchors = array( @@ -140,12 +139,6 @@ protected function doTestLanguageBlockAnonymous($block_label) { foreach ($language_switcher->ul->li as $link) { $classes = explode(" ", (string) $link['class']); list($langcode) = array_intersect($classes, array('en', 'fr')); - if (in_array('active', $classes)) { - $links['active'][] = $langcode; - } - else { - $links['inactive'][] = $langcode; - } $anchor_classes = explode(" ", (string) $link->a['class']); if (in_array('active', $anchor_classes)) { $anchors['active'][] = $langcode; @@ -155,7 +148,6 @@ protected function doTestLanguageBlockAnonymous($block_label) { } $labels[] = (string) $link->a; } - $this->assertIdentical($links, array('active' => array('en'), 'inactive' => array('fr')), 'Only the current language list item is marked as active on the language switcher block.'); $this->assertIdentical($anchors, array('active' => array('en'), 'inactive' => array('fr')), 'Only the current language anchor is marked as active on the language switcher block.'); $this->assertIdentical($labels, array('English', 'français'), 'The language links labels are in their own language on the language switcher block.'); }