diff --git a/core/modules/language/src/Tests/LanguageSwitchingTest.php b/core/modules/language/src/Tests/LanguageSwitchingTest.php
index 4a2d245..b6801e7 100644
--- a/core/modules/language/src/Tests/LanguageSwitchingTest.php
+++ b/core/modules/language/src/Tests/LanguageSwitchingTest.php
@@ -125,7 +125,7 @@ protected function doTestLanguageBlockAnonymous($block_label) {
     $this->assertText($block_label, 'Language switcher block found.');
 
     // Assert that only the current language is marked as active.
-    list($language_switcher) = $this->xpath('//div[@id=:id]/div[contains(@class, "content")]', array(':id' => 'block-test-language-block'));
+    $language_switcher_item = $this->xpath('//div[@id=:id]//li', array(':id' => 'block-test-language-block'));
     $links = array(
       'active' => array(),
       'inactive' => array(),
@@ -134,7 +134,7 @@ protected function doTestLanguageBlockAnonymous($block_label) {
       'active' => array(),
       'inactive' => array(),
     );
-    foreach ($language_switcher->ul->li as $link) {
+    foreach ($language_switcher_item as $link) {
       $classes = explode(" ", (string) $link['class']);
       list($langcode) = array_intersect($classes, array('en', 'fr'));
       if (in_array('active', $classes)) {
@@ -156,6 +156,33 @@ protected function doTestLanguageBlockAnonymous($block_label) {
   }
 
   /**
+   * Functional tests for the operation dropdown display type.
+   */
+  function testLanguageBlockOperations() {
+    // Enable the language switching block..
+    $block = $this->drupalPlaceBlock('language_block:' . LanguageInterface::TYPE_INTERFACE, array(
+      'id' => 'test_language_block',
+      // Ensure a 2-byte UTF-8 sequence is in the tested output.
+      'label' => $this->randomName(8) . '×',
+      // Display block as operations dropdown.
+      'block_type' => 'type',
+    ));
+
+    // Add language.
+    $edit = array(
+      'predefined_langcode' => 'fr',
+    );
+    $this->drupalPostForm('admin/config/regional/language/add', $edit, t('Add language'));
+
+    // Enable URL language detection and selection.
+    $edit = array('language_interface[enabled][language-url]' => '1');
+    $this->drupalPostForm('admin/config/regional/language/detection', $edit, t('Save settings'));
+
+    $operations_dropdown = $this->xpath('//div[@id=:id]//ul[contains(@class, "dropbutton")]', array(':id' => 'block-test-language-block')); 
+    $this->assertTrue($operations_dropdown, 'Language block has been set to operations dropdown display mode.');
+  }
+
+  /**
    * Test active class on links when switching languages.
    */
   function testLanguageLinkActiveClass() {
