diff --git a/core/modules/language/src/Tests/AdminPathEntityConverterLanguageTest.php b/core/modules/language/tests/src/Functional/AdminPathEntityConverterLanguageTest.php
similarity index 89%
rename from core/modules/language/src/Tests/AdminPathEntityConverterLanguageTest.php
rename to core/modules/language/tests/src/Functional/AdminPathEntityConverterLanguageTest.php
index 3cc00f9..bd46a40 100644
--- a/core/modules/language/src/Tests/AdminPathEntityConverterLanguageTest.php
+++ b/core/modules/language/tests/src/Functional/AdminPathEntityConverterLanguageTest.php
@@ -1,16 +1,16 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\language\Entity\ConfigurableLanguage;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Test administration path based conversion of entities.
  *
  * @group language
  */
-class AdminPathEntityConverterLanguageTest extends WebTestBase {
+class AdminPathEntityConverterLanguageTest extends BrowserTestBase {
 
   public static $modules = array('language', 'language_test');
 
diff --git a/core/modules/language/src/Tests/EntityTypeWithoutLanguageFormTest.php b/core/modules/language/tests/src/Functional/EntityTypeWithoutLanguageFormTest.php
similarity index 87%
rename from core/modules/language/src/Tests/EntityTypeWithoutLanguageFormTest.php
rename to core/modules/language/tests/src/Functional/EntityTypeWithoutLanguageFormTest.php
index 20a3532..14d5473 100644
--- a/core/modules/language/src/Tests/EntityTypeWithoutLanguageFormTest.php
+++ b/core/modules/language/tests/src/Functional/EntityTypeWithoutLanguageFormTest.php
@@ -1,8 +1,8 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Tests entity type without language support.
@@ -12,7 +12,7 @@
  *
  * @group language
  */
-class EntityTypeWithoutLanguageFormTest extends WebTestBase {
+class EntityTypeWithoutLanguageFormTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
diff --git a/core/modules/language/src/Tests/LanguageBlockSettingsVisibilityTest.php b/core/modules/language/tests/src/Functional/LanguageBlockSettingsVisibilityTest.php
similarity index 41%
rename from core/modules/language/src/Tests/LanguageBlockSettingsVisibilityTest.php
rename to core/modules/language/tests/src/Functional/LanguageBlockSettingsVisibilityTest.php
index ee6912e..601da4d 100644
--- a/core/modules/language/src/Tests/LanguageBlockSettingsVisibilityTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageBlockSettingsVisibilityTest.php
@@ -1,15 +1,15 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Tests that the language settings on block config appears correctly.
  *
  * @group language
  */
-class LanguageBlockSettingsVisibilityTest extends WebTestBase {
+class LanguageBlockSettingsVisibilityTest extends BrowserTestBase {
 
   public static $modules = array('block', 'language');
 
@@ -18,10 +18,17 @@ public function testUnnecessaryLanguageSettingsVisibility() {
     $this->drupalLogin($admin_user);
     $this->drupalPostForm('admin/config/regional/language/add', array('predefined_langcode' => 'hu'), t('Add language'));
     $this->drupalGet('admin/structure/block/add/system_menu_block:admin/stark');
-    $this->assertNoFieldByXPath('//input[@id="edit-visibility-language-langcodes-und"]', NULL, '\'Not specified\' option does not appear at block config, language settings section.');
-    $this->assertNoFieldByXpath('//input[@id="edit-visibility-language-langcodes-zxx"]', NULL, '\'Not applicable\' option does not appear at block config, language settings section.');
-    $this->assertFieldByXPath('//input[@id="edit-visibility-language-langcodes-en"]', NULL, '\'English\' option appears at block config, language settings section.');
-    $this->assertFieldByXpath('//input[@id="edit-visibility-language-langcodes-hu"]', NULL, '\'Hungarian\' option appears at block config, language settings section.');
+
+    // 'Not specified' option does not appear at block config, language settings
+    // section.
+    $this->assertSession()->fieldNotExists('edit-visibility-language-langcodes-und');
+    // 'Not applicable' option does not appear.
+    $this->assertSession()->fieldNotExists('edit-visibility-language-langcodes-zxx');
+
+    // // 'English' option appears..
+    $this->assertSession()->fieldExists('edit-visibility-language-langcodes-en');
+    // // 'Hungarian' option appears..
+    $this->assertSession()->fieldExists('edit-visibility-language-langcodes-hu');
   }
 
 }
diff --git a/core/modules/language/src/Tests/LanguageBrowserDetectionTest.php b/core/modules/language/tests/src/Functional/LanguageBrowserDetectionTest.php
similarity index 96%
rename from core/modules/language/src/Tests/LanguageBrowserDetectionTest.php
rename to core/modules/language/tests/src/Functional/LanguageBrowserDetectionTest.php
index 3991b2a..1b1382a 100644
--- a/core/modules/language/src/Tests/LanguageBrowserDetectionTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageBrowserDetectionTest.php
@@ -1,15 +1,15 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Tests browser language detection.
  *
  * @group language
  */
-class LanguageBrowserDetectionTest extends WebTestBase {
+class LanguageBrowserDetectionTest extends BrowserTestBase {
 
   public static $modules = array('language');
 
diff --git a/core/modules/language/src/Tests/LanguageConfigOverrideImportTest.php b/core/modules/language/tests/src/Functional/LanguageConfigOverrideImportTest.php
similarity index 96%
rename from core/modules/language/src/Tests/LanguageConfigOverrideImportTest.php
rename to core/modules/language/tests/src/Functional/LanguageConfigOverrideImportTest.php
index 182c3fe..76d97fb 100644
--- a/core/modules/language/src/Tests/LanguageConfigOverrideImportTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageConfigOverrideImportTest.php
@@ -1,16 +1,16 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\language\Entity\ConfigurableLanguage;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Ensures the language config overrides can be synchronized.
  *
  * @group language
  */
-class LanguageConfigOverrideImportTest extends WebTestBase {
+class LanguageConfigOverrideImportTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
diff --git a/core/modules/language/src/Tests/LanguageConfigSchemaTest.php b/core/modules/language/tests/src/Functional/LanguageConfigSchemaTest.php
similarity index 93%
rename from core/modules/language/src/Tests/LanguageConfigSchemaTest.php
rename to core/modules/language/tests/src/Functional/LanguageConfigSchemaTest.php
index 97cbbb7..2ea76d8 100644
--- a/core/modules/language/src/Tests/LanguageConfigSchemaTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageConfigSchemaTest.php
@@ -1,16 +1,16 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\config\Tests\SchemaCheckTestTrait;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Ensures the language config schema is correct.
  *
  * @group language
  */
-class LanguageConfigSchemaTest extends WebTestBase {
+class LanguageConfigSchemaTest extends BrowserTestBase {
 
   use SchemaCheckTestTrait;
 
diff --git a/core/modules/language/src/Tests/LanguageConfigurationElementTest.php b/core/modules/language/tests/src/Functional/LanguageConfigurationElementTest.php
similarity index 98%
rename from core/modules/language/src/Tests/LanguageConfigurationElementTest.php
rename to core/modules/language/tests/src/Functional/LanguageConfigurationElementTest.php
index 93b821d..10d0bfa 100644
--- a/core/modules/language/src/Tests/LanguageConfigurationElementTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageConfigurationElementTest.php
@@ -1,11 +1,11 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\Core\Language\LanguageInterface;
 use Drupal\language\Entity\ConfigurableLanguage;
 use Drupal\language\Entity\ContentLanguageSettings;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 use Drupal\taxonomy\Entity\Vocabulary;
 
 /**
@@ -13,7 +13,7 @@
  *
  * @group language
  */
-class LanguageConfigurationElementTest extends WebTestBase {
+class LanguageConfigurationElementTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
diff --git a/core/modules/language/src/Tests/LanguageConfigurationTest.php b/core/modules/language/tests/src/Functional/LanguageConfigurationTest.php
similarity index 89%
rename from core/modules/language/src/Tests/LanguageConfigurationTest.php
rename to core/modules/language/tests/src/Functional/LanguageConfigurationTest.php
index cf049f1..e53b05e 100644
--- a/core/modules/language/src/Tests/LanguageConfigurationTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageConfigurationTest.php
@@ -1,17 +1,17 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\Core\Language\LanguageInterface;
 use Drupal\language\Entity\ConfigurableLanguage;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Adds and configures languages to check negotiation changes.
  *
  * @group language
  */
-class LanguageConfigurationTest extends WebTestBase {
+class LanguageConfigurationTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
@@ -34,11 +34,13 @@ function testLanguageConfiguration() {
 
     // Check if the Default English language has no path prefix.
     $this->drupalGet('admin/config/regional/language/detection/url');
-    $this->assertFieldByXPath('//input[@name="prefix[en]"]', '', 'Default English has no path prefix.');
+    // Default English has no path prefix.
+    $this->assertSession()->fieldValueEquals('prefix[en]', '');
 
     // Check that Add language is a primary button.
     $this->drupalGet('admin/config/regional/language/add');
-    $this->assertFieldByXPath('//input[contains(@class, "button--primary")]', 'Add language', 'Add language is a primary button');
+    $button = $this->assertSession()->buttonExists('Add language');
+    $this->assertTrue($button->hasClass('button--primary'));
 
     // Add predefined language.
     $edit = array(
@@ -53,10 +55,10 @@ function testLanguageConfiguration() {
 
     // Check if the Default English language has no path prefix.
     $this->drupalGet('admin/config/regional/language/detection/url');
-    $this->assertFieldByXPath('//input[@name="prefix[en]"]', '', 'Default English has no path prefix.');
+    $this->assertSession()->fieldValueEquals('prefix[en]', '');
     // Check if French has a path prefix.
     $this->drupalGet('admin/config/regional/language/detection/url');
-    $this->assertFieldByXPath('//input[@name="prefix[fr]"]', 'fr', 'French has a path prefix.');
+    $this->assertSession()->fieldValueEquals('prefix[fr]', 'fr');
 
     // Check if we can change the default language.
     $this->drupalGet('admin/config/regional/language');
@@ -74,17 +76,17 @@ function testLanguageConfiguration() {
     // Check if a valid language prefix is added after changing the default
     // language.
     $this->drupalGet('admin/config/regional/language/detection/url');
-    $this->assertFieldByXPath('//input[@name="prefix[en]"]', 'en', 'A valid path prefix has been added to the previous default language.');
+    $this->assertSession()->fieldValueEquals('prefix[en]', 'en');
     // Check if French still has a path prefix.
     $this->drupalGet('admin/config/regional/language/detection/url');
-    $this->assertFieldByXPath('//input[@name="prefix[fr]"]', 'fr', 'French still has a path prefix.');
+    $this->assertSession()->fieldValueEquals('prefix[fr]', 'fr');
 
     // Check that prefix can be changed.
     $edit = array(
       'prefix[fr]' => 'french',
     );
     $this->drupalPostForm(NULL, $edit, t('Save configuration'));
-    $this->assertFieldByXPath('//input[@name="prefix[fr]"]', 'french', 'French path prefix has changed.');
+    $this->assertSession()->fieldValueEquals('prefix[fr]', 'french');
 
     // Check that the prefix can be removed.
     $edit = array(
@@ -169,10 +171,7 @@ function testLanguageConfigurationWeight() {
     $this->checkConfigurableLanguageWeight('after re-ordering');
 
     // Remove predefined language.
-    $edit = array(
-      'confirm' => 1,
-    );
-    $this->drupalPostForm('admin/config/regional/language/delete/fr', $edit, 'Delete');
+    $this->drupalPostForm('admin/config/regional/language/delete/fr', array(), 'Delete');
     $this->checkConfigurableLanguageWeight('after deleting a language');
   }
 
diff --git a/core/modules/language/src/Tests/LanguageCustomLanguageConfigurationTest.php b/core/modules/language/tests/src/Functional/LanguageCustomLanguageConfigurationTest.php
similarity index 96%
rename from core/modules/language/src/Tests/LanguageCustomLanguageConfigurationTest.php
rename to core/modules/language/tests/src/Functional/LanguageCustomLanguageConfigurationTest.php
index dbd35cd..6c01c00 100644
--- a/core/modules/language/src/Tests/LanguageCustomLanguageConfigurationTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageCustomLanguageConfigurationTest.php
@@ -1,8 +1,8 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 use Drupal\Core\Language\Language;
 use Drupal\Core\Language\LanguageInterface;
 
@@ -11,7 +11,7 @@
  *
  * @group language
  */
-class LanguageCustomLanguageConfigurationTest extends WebTestBase {
+class LanguageCustomLanguageConfigurationTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
diff --git a/core/modules/language/src/Tests/LanguageListModuleInstallTest.php b/core/modules/language/tests/src/Functional/LanguageListModuleInstallTest.php
similarity index 89%
rename from core/modules/language/src/Tests/LanguageListModuleInstallTest.php
rename to core/modules/language/tests/src/Functional/LanguageListModuleInstallTest.php
index 3df9bdc..2b5ad7e 100644
--- a/core/modules/language/src/Tests/LanguageListModuleInstallTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageListModuleInstallTest.php
@@ -1,8 +1,8 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Tests enabling Language if a module exists that calls
@@ -10,7 +10,7 @@
  *
  * @group language
  */
-class LanguageListModuleInstallTest extends WebTestBase {
+class LanguageListModuleInstallTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
diff --git a/core/modules/language/src/Tests/LanguageListTest.php b/core/modules/language/tests/src/Functional/LanguageListTest.php
similarity index 93%
rename from core/modules/language/src/Tests/LanguageListTest.php
rename to core/modules/language/tests/src/Functional/LanguageListTest.php
index d407530..f8a0b35 100644
--- a/core/modules/language/src/Tests/LanguageListTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageListTest.php
@@ -1,9 +1,9 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\language\Entity\ConfigurableLanguage;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 use Drupal\Core\Language\Language;
 use Drupal\Core\Language\LanguageInterface;
 
@@ -12,7 +12,7 @@
  *
  * @group language
  */
-class LanguageListTest extends WebTestBase {
+class LanguageListTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
@@ -176,9 +176,20 @@ function testLanguageList() {
     $this->assertResponse(403, 'Can not delete locked language');
 
     // Ensure that NL cannot be set default when it's not available.
+    // First create the NL language.
+    $edit = array(
+      'predefined_langcode' => 'nl',
+    );
+    $this->drupalPostForm('admin/config/regional/language/add', $edit, 'Add language');
+
+    // Load the form which has now the additional NL language option.
     $this->drupalGet('admin/config/regional/language');
-    $extra_values = '&site_default_language=nl';
-    $this->drupalPostForm(NULL, array(), t('Save configuration'), array(), array(), NULL, $extra_values);
+
+    // Delete the NL language in the background.
+    $language_storage = $this->container->get('entity_type.manager')->getStorage('configurable_language');
+    $language_storage->load('nl')->delete();
+
+    $this->drupalPostForm(NULL, array('site_default_language' => 'nl'), 'Save configuration');
     $this->assertText(t('Selected default language no longer exists.'));
     $this->assertNoFieldChecked('edit-site-default-language-xx', 'The previous default language got deselected.');
   }
diff --git a/core/modules/language/src/Tests/LanguageLocaleListTest.php b/core/modules/language/tests/src/Functional/LanguageLocaleListTest.php
similarity index 84%
rename from core/modules/language/src/Tests/LanguageLocaleListTest.php
rename to core/modules/language/tests/src/Functional/LanguageLocaleListTest.php
index dd3e02a..5ab3662 100644
--- a/core/modules/language/src/Tests/LanguageLocaleListTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageLocaleListTest.php
@@ -1,15 +1,15 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Adds a new language with translations and tests language list order.
  *
  * @group language
  */
-class LanguageLocaleListTest extends WebTestBase {
+class LanguageLocaleListTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
@@ -57,9 +57,11 @@ function testLanguageLocaleList() {
 
     // Get language list displayed in select list.
     $this->drupalGet('fr/admin/config/regional/language/add');
-    $select = $this->xpath('//select[@id="edit-predefined-langcode"]');
-    $select_element = (array) end($select);
-    $options = $select_element['option'];
+    $option_elements = $this->xpath('//select[@id="edit-predefined-langcode/option"]');
+    $options = [];
+    foreach ($option_elements as $option_element) {
+      $options[] = $option_element->getText();
+    }
     // Remove the 'Custom language...' option form the end.
     array_pop($options);
     // Order language list.
diff --git a/core/modules/language/src/Tests/LanguageNegotiationContentEntityTest.php b/core/modules/language/tests/src/Functional/LanguageNegotiationContentEntityTest.php
similarity index 98%
rename from core/modules/language/src/Tests/LanguageNegotiationContentEntityTest.php
rename to core/modules/language/tests/src/Functional/LanguageNegotiationContentEntityTest.php
index ba0a4db..8991437 100644
--- a/core/modules/language/src/Tests/LanguageNegotiationContentEntityTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageNegotiationContentEntityTest.php
@@ -1,6 +1,6 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\Component\Render\FormattableMarkup;
 use Drupal\Core\Language\LanguageInterface;
@@ -8,7 +8,7 @@
 use Drupal\language\Entity\ConfigurableLanguage;
 use Drupal\language\Plugin\LanguageNegotiation\LanguageNegotiationContentEntity;
 use Drupal\language\Plugin\LanguageNegotiation\LanguageNegotiationUrl;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 use Symfony\Cmf\Component\Routing\RouteObjectInterface;
 use Symfony\Component\HttpFoundation\Request;
 use Symfony\Component\Routing\Route;
@@ -18,7 +18,7 @@
  *
  * @group language
  */
-class LanguageNegotiationContentEntityTest extends WebTestBase {
+class LanguageNegotiationContentEntityTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
diff --git a/core/modules/language/src/Tests/LanguageNegotiationInfoTest.php b/core/modules/language/tests/src/Functional/LanguageNegotiationInfoTest.php
similarity index 97%
rename from core/modules/language/src/Tests/LanguageNegotiationInfoTest.php
rename to core/modules/language/tests/src/Functional/LanguageNegotiationInfoTest.php
index ee4c6d4..9e81989 100644
--- a/core/modules/language/src/Tests/LanguageNegotiationInfoTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageNegotiationInfoTest.php
@@ -1,17 +1,17 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\Core\Language\LanguageInterface;
 use Drupal\language\Plugin\LanguageNegotiation\LanguageNegotiationUI;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Tests alterations to language types/negotiation info.
  *
  * @group language
  */
-class LanguageNegotiationInfoTest extends WebTestBase {
+class LanguageNegotiationInfoTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
@@ -105,7 +105,8 @@ function testInfoAlterations() {
     $this->assertFalse(isset($negotiation[$interface_method_id]), 'Interface language negotiation method removed from the stored settings.');
 
     $this->drupalGet('admin/config/regional/language/detection');
-    $this->assertNoFieldByName($form_field, NULL, 'Interface language negotiation method unavailable.');
+    // Interface language negotiation method unavailable..
+    $this->assertNoFieldByName($form_field, NULL);
 
     // Check that type-specific language negotiation methods can be assigned
     // only to the corresponding language types.
diff --git a/core/modules/language/src/Tests/LanguagePathMonolingualTest.php b/core/modules/language/tests/src/Functional/LanguagePathMonolingualTest.php
similarity index 94%
rename from core/modules/language/src/Tests/LanguagePathMonolingualTest.php
rename to core/modules/language/tests/src/Functional/LanguagePathMonolingualTest.php
index 510d805..681b378 100644
--- a/core/modules/language/src/Tests/LanguagePathMonolingualTest.php
+++ b/core/modules/language/tests/src/Functional/LanguagePathMonolingualTest.php
@@ -1,15 +1,15 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Confirm that paths are not changed on monolingual non-English sites.
  *
  * @group language
  */
-class LanguagePathMonolingualTest extends WebTestBase {
+class LanguagePathMonolingualTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
diff --git a/core/modules/language/src/Tests/LanguageSelectorTranslatableTest.php b/core/modules/language/tests/src/Functional/LanguageSelectorTranslatableTest.php
similarity index 88%
rename from core/modules/language/src/Tests/LanguageSelectorTranslatableTest.php
rename to core/modules/language/tests/src/Functional/LanguageSelectorTranslatableTest.php
index 84d6779..8f2b5e0 100644
--- a/core/modules/language/src/Tests/LanguageSelectorTranslatableTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageSelectorTranslatableTest.php
@@ -1,15 +1,15 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Tests the content translation settings language selector options.
  *
  * @group language
  */
-class LanguageSelectorTranslatableTest extends WebTestBase {
+class LanguageSelectorTranslatableTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
@@ -82,7 +82,7 @@ public function testLanguageStringSelector() {
     $elements = $this->xpath('//select[@id=:id]//option[@value=:option]', array(':id' => 'edit-settings-user-user-settings-language-langcode', ':option' => 'en'));
 
     // Check that the language text is translated.
-    $this->assertEqual((string) $elements[0], $name_translation, 'Checking the option string English is translated to Spanish.');
+    $this->assertEqual($elements[0]->getText(), $name_translation, 'Checking the option string English is translated to Spanish.');
   }
 
 }
diff --git a/core/modules/language/src/Tests/LanguageSwitchingTest.php b/core/modules/language/tests/src/Functional/LanguageSwitchingTest.php
similarity index 99%
rename from core/modules/language/src/Tests/LanguageSwitchingTest.php
rename to core/modules/language/tests/src/Functional/LanguageSwitchingTest.php
index c076e6f..11adb12 100644
--- a/core/modules/language/src/Tests/LanguageSwitchingTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageSwitchingTest.php
@@ -1,19 +1,19 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\language\Entity\ConfigurableLanguage;
 use Drupal\language\Plugin\LanguageNegotiation\LanguageNegotiationUrl;
 use Drupal\menu_link_content\Entity\MenuLinkContent;
 use Drupal\Core\Language\LanguageInterface;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 
 /**
  * Functional tests for the language switching feature.
  *
  * @group language
  */
-class LanguageSwitchingTest extends WebTestBase {
+class LanguageSwitchingTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
diff --git a/core/modules/language/src/Tests/LanguageTourTest.php b/core/modules/language/tests/src/Functional/LanguageTourTest.php
similarity index 96%
rename from core/modules/language/src/Tests/LanguageTourTest.php
rename to core/modules/language/tests/src/Functional/LanguageTourTest.php
index 7778367..31c1ce2 100644
--- a/core/modules/language/src/Tests/LanguageTourTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageTourTest.php
@@ -1,6 +1,6 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\tour\Tests\TourTestBase;
 
diff --git a/core/modules/language/src/Tests/LanguageUILanguageNegotiationTest.php b/core/modules/language/tests/src/Functional/LanguageUILanguageNegotiationTest.php
similarity index 98%
rename from core/modules/language/src/Tests/LanguageUILanguageNegotiationTest.php
rename to core/modules/language/tests/src/Functional/LanguageUILanguageNegotiationTest.php
index ef2abee..30452aa 100644
--- a/core/modules/language/src/Tests/LanguageUILanguageNegotiationTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageUILanguageNegotiationTest.php
@@ -1,6 +1,6 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\Core\Url;
 use Drupal\language\Entity\ConfigurableLanguage;
@@ -10,7 +10,7 @@
 use Drupal\language\Plugin\LanguageNegotiation\LanguageNegotiationUrl;
 use Drupal\user\Plugin\LanguageNegotiation\LanguageNegotiationUser;
 use Drupal\user\Plugin\LanguageNegotiation\LanguageNegotiationUserAdmin;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 use Drupal\Core\Language\Language;
 use Drupal\Core\Language\LanguageInterface;
 use Symfony\Component\HttpFoundation\Request;
@@ -37,7 +37,7 @@
  *
  * @group language
  */
-class LanguageUILanguageNegotiationTest extends WebTestBase {
+class LanguageUILanguageNegotiationTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
@@ -136,7 +136,7 @@ function testUILanguageNegotiation() {
       'http_header' => $http_header_browser_fallback,
       'message' => 'SELECTED: UI language is switched based on selected language.',
     );
-    $this->runTest($test);
+    $this->doTest($test);
 
     // An invalid language is selected.
     $this->config('language.negotiation')->set('selected_langcode', NULL)->save();
@@ -148,7 +148,7 @@ function testUILanguageNegotiation() {
       'http_header' => $http_header_browser_fallback,
       'message' => 'SELECTED > DEFAULT: UI language is switched based on selected language.',
     );
-    $this->runTest($test);
+    $this->doTest($test);
 
     // No selected language is available.
     $this->config('language.negotiation')->set('selected_langcode', $langcode_unknown)->save();
@@ -160,7 +160,7 @@ function testUILanguageNegotiation() {
       'http_header' => $http_header_browser_fallback,
       'message' => 'SELECTED > DEFAULT: UI language is switched based on selected language.',
     );
-    $this->runTest($test);
+    $this->doTest($test);
 
     $tests = array(
       // Default, browser preference should have no influence.
@@ -211,7 +211,7 @@ function testUILanguageNegotiation() {
     );
 
     foreach ($tests as $test) {
-      $this->runTest($test);
+      $this->doTest($test);
     }
 
     // Unknown language prefix should return 404.
@@ -240,7 +240,7 @@ function testUILanguageNegotiation() {
       'http_header' => array(),
       'message' => 'USER > DEFAULT: no preferred user language setting, the UI language is default',
     );
-    $this->runTest($test);
+    $this->doTest($test);
 
     // Set preferred langcode for user to unknown language.
     $account = $this->loggedInUser;
@@ -255,7 +255,7 @@ function testUILanguageNegotiation() {
       'http_header' => array(),
       'message' => 'USER > DEFAULT: invalid preferred user language setting, the UI language is default',
     );
-    $this->runTest($test);
+    $this->doTest($test);
 
     // Set preferred langcode for user to non default.
     $account->preferred_langcode = $langcode;
@@ -269,7 +269,7 @@ function testUILanguageNegotiation() {
       'http_header' => array(),
       'message' => 'USER > DEFAULT: defined preferred user language setting, the UI language is based on user setting',
     );
-    $this->runTest($test);
+    $this->doTest($test);
 
     // Set preferred admin langcode for user to NULL.
     $account->preferred_admin_langcode = NULL;
@@ -283,7 +283,7 @@ function testUILanguageNegotiation() {
       'http_header' => array(),
       'message' => 'USER ADMIN > DEFAULT: no preferred user admin language setting, the UI language is default',
     );
-    $this->runTest($test);
+    $this->doTest($test);
 
     // Set preferred admin langcode for user to unknown language.
     $account->preferred_admin_langcode = $langcode_unknown;
@@ -297,7 +297,7 @@ function testUILanguageNegotiation() {
       'http_header' => array(),
       'message' => 'USER ADMIN > DEFAULT: invalid preferred user admin language setting, the UI language is default',
     );
-    $this->runTest($test);
+    $this->doTest($test);
 
     // Set preferred admin langcode for user to non default.
     $account->preferred_admin_langcode = $langcode;
@@ -311,7 +311,7 @@ function testUILanguageNegotiation() {
       'http_header' => array(),
       'message' => 'USER ADMIN > DEFAULT: defined preferred user admin language setting, the UI language is based on user setting',
     );
-    $this->runTest($test);
+    $this->doTest($test);
 
     // Go by session preference.
     $language_negotiation_session_param = $this->randomMachineName();
@@ -337,11 +337,11 @@ function testUILanguageNegotiation() {
       ),
     );
     foreach ($tests as $test) {
-      $this->runTest($test);
+      $this->doTest($test);
     }
   }
 
-  protected function runTest($test) {
+  protected function doTest($test) {
     $test += array('path_options' => []);
     if (!empty($test['language_negotiation'])) {
       $method_weights = array_flip($test['language_negotiation']);
diff --git a/core/modules/language/src/Tests/LanguageUrlRewritingTest.php b/core/modules/language/tests/src/Functional/LanguageUrlRewritingTest.php
similarity index 96%
rename from core/modules/language/src/Tests/LanguageUrlRewritingTest.php
rename to core/modules/language/tests/src/Functional/LanguageUrlRewritingTest.php
index 5cd80dc..e08eb0a 100644
--- a/core/modules/language/src/Tests/LanguageUrlRewritingTest.php
+++ b/core/modules/language/tests/src/Functional/LanguageUrlRewritingTest.php
@@ -1,12 +1,12 @@
 <?php
 
-namespace Drupal\language\Tests;
+namespace Drupal\Tests\language\Functional;
 
 use Drupal\Core\Language\Language;
 use Drupal\Core\Language\LanguageInterface;
 use Drupal\Core\Url;
 use Drupal\language\Plugin\LanguageNegotiation\LanguageNegotiationUrl;
-use Drupal\simpletest\WebTestBase;
+use Drupal\Tests\BrowserTestBase;
 use Symfony\Component\HttpFoundation\Request;
 
 /**
@@ -14,7 +14,7 @@
  *
  * @group language
  */
-class LanguageUrlRewritingTest extends WebTestBase {
+class LanguageUrlRewritingTest extends BrowserTestBase {
 
   /**
    * Modules to enable.
@@ -90,9 +90,8 @@ private function checkUrl(LanguageInterface $language, $message1, $message2) {
     // we can always check the prefixed URL.
     $prefixes = language_negotiation_url_prefixes();
     $stored_prefix = isset($prefixes[$language->getId()]) ? $prefixes[$language->getId()] : $this->randomMachineName();
-    if ($this->assertNotEqual($stored_prefix, $prefix, $message1)) {
-      $prefix = $stored_prefix;
-    }
+    $this->assertNotEqual($stored_prefix, $prefix, $message1);
+    $prefix = $stored_prefix;
 
     $this->drupalGet("$prefix/$path");
     $this->assertResponse(404, $message2);
diff --git a/core/modules/language/src/Tests/Migrate/MigrateLanguageTest.php b/core/modules/language/tests/src/Kernel/Migrate/d6/MigrateLanguageTest.php
similarity index 96%
rename from core/modules/language/src/Tests/Migrate/MigrateLanguageTest.php
rename to core/modules/language/tests/src/Kernel/Migrate/d6/MigrateLanguageTest.php
index 6bdd1f2..72d7ab8 100644
--- a/core/modules/language/src/Tests/Migrate/MigrateLanguageTest.php
+++ b/core/modules/language/tests/src/Kernel/Migrate/d6/MigrateLanguageTest.php
@@ -1,6 +1,6 @@
 <?php
 
-namespace Drupal\language\Tests\Migrate;
+namespace Drupal\Tests\language\Kernel\Migrate\d6;
 
 use Drupal\language\ConfigurableLanguageInterface;
 use Drupal\language\Entity\ConfigurableLanguage;
diff --git a/core/modules/simpletest/src/TestBase.php b/core/modules/simpletest/src/TestBase.php
index 6fa40a3..f56854c 100644
--- a/core/modules/simpletest/src/TestBase.php
+++ b/core/modules/simpletest/src/TestBase.php
@@ -7,13 +7,11 @@
 use Drupal\Component\Utility\Crypt;
 use Drupal\Component\Utility\SafeMarkup;
 use Drupal\Core\Database\Database;
-use Drupal\Core\Config\ConfigImporter;
-use Drupal\Core\Config\StorageComparer;
-use Drupal\Core\Config\StorageInterface;
 use Drupal\Core\Site\Settings;
 use Drupal\Core\StreamWrapper\PublicStream;
 use Drupal\Core\Test\TestDatabase;
 use Drupal\Core\Utility\Error;
+use Drupal\Tests\ConfigTestTrait;
 use Drupal\Tests\RandomGeneratorTrait;
 use Drupal\Tests\SessionTestTrait;
 
@@ -27,6 +25,7 @@
   use SessionTestTrait;
   use RandomGeneratorTrait;
   use AssertHelperTrait;
+  use ConfigTestTrait;
 
   /**
    * The test run ID.
@@ -1538,51 +1537,6 @@ public static function filePreDeleteCallback($path) {
   }
 
   /**
-   * Returns a ConfigImporter object to import test importing of configuration.
-   *
-   * @return \Drupal\Core\Config\ConfigImporter
-   *   The ConfigImporter object.
-   */
-  public function configImporter() {
-    if (!$this->configImporter) {
-      // Set up the ConfigImporter object for testing.
-      $storage_comparer = new StorageComparer(
-        $this->container->get('config.storage.sync'),
-        $this->container->get('config.storage'),
-        $this->container->get('config.manager')
-      );
-      $this->configImporter = new ConfigImporter(
-        $storage_comparer,
-        $this->container->get('event_dispatcher'),
-        $this->container->get('config.manager'),
-        $this->container->get('lock'),
-        $this->container->get('config.typed'),
-        $this->container->get('module_handler'),
-        $this->container->get('module_installer'),
-        $this->container->get('theme_handler'),
-        $this->container->get('string_translation')
-      );
-    }
-    // Always recalculate the changelist when called.
-    return $this->configImporter->reset();
-  }
-
-  /**
-   * Copies configuration objects from source storage to target storage.
-   *
-   * @param \Drupal\Core\Config\StorageInterface $source_storage
-   *   The source config storage service.
-   * @param \Drupal\Core\Config\StorageInterface $target_storage
-   *   The target config storage service.
-   */
-  public function copyConfig(StorageInterface $source_storage, StorageInterface $target_storage) {
-    $target_storage->deleteAll();
-    foreach ($source_storage->listAll() as $name) {
-      $target_storage->write($name, $source_storage->read($name));
-    }
-  }
-
-  /**
    * Configuration accessor for tests. Returns non-overridden configuration.
    *
    * @param $name
diff --git a/core/tests/Drupal/FunctionalTests/AssertLegacyTrait.php b/core/tests/Drupal/FunctionalTests/AssertLegacyTrait.php
index 6ca9f85..81da04a 100644
--- a/core/tests/Drupal/FunctionalTests/AssertLegacyTrait.php
+++ b/core/tests/Drupal/FunctionalTests/AssertLegacyTrait.php
@@ -129,6 +129,27 @@ protected function assertFieldByName($name, $value = NULL) {
   }
 
   /**
+   * Asserts that a field exists with the given name and value.
+   *
+   * @param string $name
+   *   Name of field to assert.
+   * @param string $value
+   *   (optional) Value of the field to assert. You may pass in NULL (default)
+   *   to skip checking the actual value, while still checking that the field
+   *   exists.
+   *
+   * @deprecated Scheduled for removal in Drupal 9.0.0.
+   *   Use $this->assertSession()->fieldNotExists() or
+   *   $this->assertSession()->fieldValueNotEquals() instead.
+   */
+  protected function assertNoFieldByName($name, $value = NULL) {
+    $this->assertSession()->fieldNotExists($name);
+    if ($value !== NULL) {
+      $this->assertSession()->fieldValueNotEquals($name, (string) $value);
+    }
+  }
+
+  /**
    * Asserts that a field exists with the given ID and value.
    *
    * @param string $id
@@ -344,6 +365,47 @@ protected function assertNoOption($id, $option) {
   }
 
   /**
+   * Asserts that a select option in the current page is checked.
+   *
+   * @param string $id
+   *   ID of select field to assert.
+   * @param string $option
+   *   Option to assert.
+   *
+   * @deprecated Scheduled for removal in Drupal 9.0.0.
+   *   Use $this->assertSession()->optionSelected() instead.
+   */
+  protected function assertOptionSelected($id, $option) {
+    $this->assertSession()->optionSelected($id, $option);
+  }
+
+  /**
+   * Asserts that a checkbox field in the current page is checked.
+   *
+   * @param string $id
+   *   ID of field to assert.
+   *
+   * @deprecated Scheduled for removal in Drupal 9.0.0.
+   *   Use $this->assertSession()->checkboxChecked() instead.
+   */
+  protected function assertFieldChecked($id) {
+    $this->assertSession()->checkboxChecked($id);
+  }
+
+  /**
+   * Asserts that a checkbox field in the current page is not checked.
+   *
+   * @param string $id
+   *   ID of field to assert.
+   *
+   * @deprecated Scheduled for removal in Drupal 9.0.0.
+   *   Use $this->assertSession()->checkboxNotChecked() instead.
+   */
+  protected function assertNoFieldChecked($id) {
+    $this->assertSession()->checkboxNotChecked($id);
+  }
+
+  /**
    * Passes if the raw text IS found escaped on the loaded page, fail otherwise.
    *
    * Raw text refers to the raw HTML that the page generated.
diff --git a/core/tests/Drupal/KernelTests/KernelTestBase.php b/core/tests/Drupal/KernelTests/KernelTestBase.php
index ed3875d..8807cb5 100644
--- a/core/tests/Drupal/KernelTests/KernelTestBase.php
+++ b/core/tests/Drupal/KernelTests/KernelTestBase.php
@@ -7,9 +7,6 @@
 use Drupal\Component\FileCache\FileCacheFactory;
 use Drupal\Component\Utility\Html;
 use Drupal\Component\Utility\SafeMarkup;
-use Drupal\Core\Config\ConfigImporter;
-use Drupal\Core\Config\StorageComparer;
-use Drupal\Core\Config\StorageInterface;
 use Drupal\Core\Database\Database;
 use Drupal\Core\DependencyInjection\ContainerBuilder;
 use Drupal\Core\DependencyInjection\ServiceProviderInterface;
@@ -20,6 +17,7 @@
 use Drupal\Core\Site\Settings;
 use Drupal\simpletest\AssertContentTrait;
 use Drupal\simpletest\AssertHelperTrait;
+use Drupal\Tests\ConfigTestTrait;
 use Drupal\Tests\RandomGeneratorTrait;
 use Drupal\simpletest\TestServiceProvider;
 use Symfony\Component\DependencyInjection\Reference;
@@ -55,6 +53,7 @@
   use AssertContentTrait;
   use AssertHelperTrait;
   use RandomGeneratorTrait;
+  use ConfigTestTrait;
 
   /**
    * {@inheritdoc}
@@ -1016,54 +1015,6 @@ protected function setSetting($name, $value) {
   }
 
   /**
-   * Returns a ConfigImporter object to import test configuration.
-   *
-   * @return \Drupal\Core\Config\ConfigImporter
-   *
-   * @todo Move into Config-specific test base class.
-   */
-  protected function configImporter() {
-    if (!$this->configImporter) {
-      // Set up the ConfigImporter object for testing.
-      $storage_comparer = new StorageComparer(
-        $this->container->get('config.storage.sync'),
-        $this->container->get('config.storage'),
-        $this->container->get('config.manager')
-      );
-      $this->configImporter = new ConfigImporter(
-        $storage_comparer,
-        $this->container->get('event_dispatcher'),
-        $this->container->get('config.manager'),
-        $this->container->get('lock'),
-        $this->container->get('config.typed'),
-        $this->container->get('module_handler'),
-        $this->container->get('module_installer'),
-        $this->container->get('theme_handler'),
-        $this->container->get('string_translation')
-      );
-    }
-    // Always recalculate the changelist when called.
-    return $this->configImporter->reset();
-  }
-
-  /**
-   * Copies configuration objects from a source storage to a target storage.
-   *
-   * @param \Drupal\Core\Config\StorageInterface $source_storage
-   *   The source config storage.
-   * @param \Drupal\Core\Config\StorageInterface $target_storage
-   *   The target config storage.
-   *
-   * @todo Move into Config-specific test base class.
-   */
-  protected function copyConfig(StorageInterface $source_storage, StorageInterface $target_storage) {
-    $target_storage->deleteAll();
-    foreach ($source_storage->listAll() as $name) {
-      $target_storage->write($name, $source_storage->read($name));
-    }
-  }
-
-  /**
    * Stops test execution.
    */
   protected function stop() {
diff --git a/core/tests/Drupal/Tests/BrowserTestBase.php b/core/tests/Drupal/Tests/BrowserTestBase.php
index 3beb32f..18e1b25 100644
--- a/core/tests/Drupal/Tests/BrowserTestBase.php
+++ b/core/tests/Drupal/Tests/BrowserTestBase.php
@@ -29,6 +29,7 @@
 use Drupal\simpletest\NodeCreationTrait;
 use Drupal\user\Entity\Role;
 use Drupal\user\Entity\User;
+use Drupal\Tests\ConfigTestTrait;
 use Symfony\Component\CssSelector\CssSelectorConverter;
 use Symfony\Component\HttpFoundation\Request;
 
@@ -56,6 +57,7 @@
   use ContentTypeCreationTrait {
     createContentType as drupalCreateContentType;
   }
+  use ConfigTestTrait;
 
   /**
    * Class loader.
diff --git a/core/tests/Drupal/Tests/ConfigTestTrait.php b/core/tests/Drupal/Tests/ConfigTestTrait.php
new file mode 100644
index 0000000..4316827
--- /dev/null
+++ b/core/tests/Drupal/Tests/ConfigTestTrait.php
@@ -0,0 +1,58 @@
+<?php
+
+namespace Drupal\Tests;
+
+use Drupal\Core\Config\ConfigImporter;
+use Drupal\Core\Config\StorageComparer;
+use Drupal\Core\Config\StorageInterface;
+
+/**
+ * Provides helper methods to deal with config system objects in tests.
+ */
+trait ConfigTestTrait {
+
+  /**
+   * Returns a ConfigImporter object to import test configuration.
+   *
+   * @return \Drupal\Core\Config\ConfigImporter
+   */
+  protected function configImporter() {
+    if (!$this->configImporter) {
+      // Set up the ConfigImporter object for testing.
+      $storage_comparer = new StorageComparer(
+        $this->container->get('config.storage.sync'),
+        $this->container->get('config.storage'),
+        $this->container->get('config.manager')
+      );
+      $this->configImporter = new ConfigImporter(
+        $storage_comparer,
+        $this->container->get('event_dispatcher'),
+        $this->container->get('config.manager'),
+        $this->container->get('lock'),
+        $this->container->get('config.typed'),
+        $this->container->get('module_handler'),
+        $this->container->get('module_installer'),
+        $this->container->get('theme_handler'),
+        $this->container->get('string_translation')
+      );
+    }
+    // Always recalculate the changelist when called.
+    return $this->configImporter->reset();
+  }
+
+  /**
+   * Copies configuration objects from source storage to target storage.
+   *
+   * @param \Drupal\Core\Config\StorageInterface $source_storage
+   *   The source config storage service.
+   * @param \Drupal\Core\Config\StorageInterface $target_storage
+   *   The target config storage service.
+   */
+  public function copyConfig(StorageInterface $source_storage, StorageInterface $target_storage) {
+    $target_storage->deleteAll();
+    foreach ($source_storage->listAll() as $name) {
+      $target_storage->write($name, $source_storage->read($name));
+    }
+  }
+
+}
diff --git a/core/tests/Drupal/Tests/WebAssert.php b/core/tests/Drupal/Tests/WebAssert.php
index 6156dda..d4cffd8 100644
--- a/core/tests/Drupal/Tests/WebAssert.php
+++ b/core/tests/Drupal/Tests/WebAssert.php
@@ -191,6 +191,29 @@ public function optionNotExists($select, $option, TraversableElement $container
   }
 
   /**
+   * Checks that a specific option in a select field is selected.
+   *
+   * @param string $select
+   *   One of id|name|label|value for the select field.
+   * @param string $option
+   *   The option value.
+   * @param \Behat\Mink\Element\TraversableElement $container
+   *   (optional) The document to check against. Defaults to the current page.
+   *
+   * @return \Behat\Mink\Element\NodeElement
+   *   The matching option element
+   *
+   * @throws \Behat\Mink\Exception\ElementNotFoundException
+   *   When the element doesn't exist.
+   */
+  public function optionSelected($select, $option, TraversableElement $container = NULL) {
+    $option_field = $this->optionExists($select, $option, $container);
+    $this->assert(!empty($option_field->getAttribute('selected')), sprintf('Option "%s" in select "%s" is not selected as expected.', $option, $select));
+
+    return $option_field;
+  }
+
+  /**
    * Pass if the page title is the given string.
    *
    * @param string $expected_title
