diff --git a/core/modules/simpletest/src/InstallerTestBase.php b/core/modules/simpletest/src/InstallerTestBase.php
index 92af365..5d7b6b8 100644
--- a/core/modules/simpletest/src/InstallerTestBase.php
+++ b/core/modules/simpletest/src/InstallerTestBase.php
@@ -35,7 +35,7 @@
    *
    * @var string
    */
-  protected $langcode = 'en';
+  protected $langCode = 'en';
 
   /**
    * The installation profile to install.
@@ -179,7 +179,7 @@ protected function setUp() {
    */
   protected function setUpLanguage() {
     $edit = array(
-      'langcode' => $this->langcode,
+      'langcode' => $this->langCode,
     );
     $this->drupalPostForm(NULL, $edit, $this->translations['Save and continue']);
   }
diff --git a/core/modules/simpletest/src/KernelTestBase.php b/core/modules/simpletest/src/KernelTestBase.php
index f26c5d4..0a4b510 100644
--- a/core/modules/simpletest/src/KernelTestBase.php
+++ b/core/modules/simpletest/src/KernelTestBase.php
@@ -209,8 +209,8 @@ protected function setUp() {
     // StreamWrapper APIs.
     // @todo Move StreamWrapper management into DrupalKernel.
     // @see https://drupal.org/node/2028109
-    file_prepare_directory($this->public_files_directory, FILE_CREATE_DIRECTORY | FILE_MODIFY_PERMISSIONS);
-    $this->settingsSet('file_public_path', $this->public_files_directory);
+    file_prepare_directory($this->publicFilesDirectory, FILE_CREATE_DIRECTORY | FILE_MODIFY_PERMISSIONS);
+    $this->settingsSet('file_public_path', $this->publicFilesDirectory);
     $this->streamWrappers = array();
     $this->registerStreamWrapper('public', 'Drupal\Core\StreamWrapper\PublicStream');
     // The temporary stream wrapper is able to operate both with and without
diff --git a/core/modules/simpletest/src/TestBase.php b/core/modules/simpletest/src/TestBase.php
index a766d63..21514c2 100644
--- a/core/modules/simpletest/src/TestBase.php
+++ b/core/modules/simpletest/src/TestBase.php
@@ -55,20 +55,6 @@
   protected $databasePrefix = NULL;
 
   /**
-   * The site directory of the original parent site.
-   *
-   * @var string
-   */
-  protected $originalSite;
-
-  /**
-   * The original file directory, before it was changed for testing purposes.
-   *
-   * @var string
-   */
-  protected $originalFileDirectory = NULL;
-
-  /**
    * Time limit for the test.
    */
   protected $timeLimit = 500;
@@ -133,6 +119,60 @@
   protected $verboseDirectory;
 
   /**
+   * URL to the verbose output file directory.
+   *
+   * @var string
+   */
+  protected $verboseDirectoryUrl;
+
+  /**
+   * The original configuration (variables), if available.
+   *
+   * @var string
+   * @todo Remove all remnants of $GLOBALS['conf'].
+   * @see https://drupal.org/node/2183323
+   */
+  protected $originalConf;
+
+  /**
+   * The original configuration (variables).
+   *
+   * @var string
+   */
+  protected $originalConfig;
+
+  /**
+   * The original configuration directories.
+   *
+   * An array of paths keyed by the CONFIG_*_DIRECTORY constants defined by
+   * core/includes/bootstrap.inc.
+   *
+   * @var array
+   */
+  protected $originalConfigDirectories;
+
+  /**
+   * The original container.
+   *
+   * @var \Symfony\Component\DependencyInjection\ContainerInterface
+   */
+  protected $originalContainer;
+
+  /**
+   * The original file directory, before it was changed for testing purposes.
+   *
+   * @var string
+   */
+  protected $originalFileDirectory = NULL;
+
+  /**
+   * The original language.
+   *
+   * @var \Drupal\Core\Language\LanguageInterface
+   */
+  protected $originalLanguage;
+
+  /**
    * The original database prefix when running inside Simpletest.
    *
    * @var string
@@ -140,25 +180,82 @@
   protected $originalPrefix;
 
   /**
-   * URL to the verbose output file directory.
+   * The original installation profile.
    *
    * @var string
    */
-  protected $verboseDirectoryUrl;
+  protected $originalProfile;
+
+  /**
+   * The name of the session cookie.
+   *
+   * @var string
+   */
+  protected $originalSessionName;
 
   /**
    * The settings array.
+   *
+   * @var array
    */
   protected $originalSettings;
 
   /**
+   * The original array of shutdown function callbacks.
+   *
+   * @var array
+   */
+  protected $originalShutdownCallbacks;
+
+  /**
+   * The site directory of the original parent site.
+   *
+   * @var string
+   */
+  protected $originalSite;
+
+  /**
+   * The original user, before testing began.
+   *
+   * @var \Drupal\Core\Session\AccountProxyInterface
+   */
+  protected $originalUser;
+
+  /**
    * The public file directory for the test environment.
    *
    * This is set in TestBase::prepareEnvironment().
    *
    * @var string
    */
-  protected $public_files_directory;
+  protected $publicFilesDirectory;
+
+  /**
+   * The private file directory for the test environment.
+   *
+   * This is set in TestBase::prepareEnvironment().
+   *
+   * @var string
+   */
+  protected $privateFilesDirectory;
+
+  /**
+   * The temporary file directory for the test environment.
+   *
+   * This is set in TestBase::prepareEnvironment().
+   *
+   * @var string
+   */
+  protected $tempFilesDirectory;
+
+  /**
+   * The translation file directory for the test environment.
+   *
+   * This is set in TestBase::prepareEnvironment().
+   *
+   * @var string
+   */
+  protected $translationFilesDirectory;
 
   /**
    * Whether to die in case any test assertion fails.
@@ -198,11 +295,6 @@
   protected $randomGenerator;
 
   /**
-   * The name of the session cookie.
-   */
-  protected $originalSessionName;
-
-  /**
    * Set to TRUE to strict check all configuration saved.
    *
    * @see \Drupal\Core\Config\Testing\ConfigSchemaChecker
@@ -795,6 +887,7 @@ public function run(array $methods = array()) {
     if (!isset($this->verbose)) {
       $this->verbose = $simpletest_config->get('verbose');
     }
+
     if ($this->verbose) {
       // Initialize verbose debugging.
       $this->verbose = TRUE;
@@ -1055,10 +1148,10 @@ private function prepareEnvironment() {
     file_prepare_directory($this->siteDirectory, FILE_CREATE_DIRECTORY | FILE_MODIFY_PERMISSIONS);
 
     // Prepare filesystem directory paths.
-    $this->public_files_directory = $this->siteDirectory . '/files';
-    $this->private_files_directory = $this->siteDirectory . '/private';
-    $this->temp_files_directory = $this->siteDirectory . '/temp';
-    $this->translation_files_directory = $this->siteDirectory . '/translations';
+    $this->publicFilesDirectory = $this->siteDirectory . '/files';
+    $this->privateFilesDirectory = $this->siteDirectory . '/private';
+    $this->tempFilesDirectory = $this->siteDirectory . '/temp';
+    $this->translationFilesDirectory = $this->siteDirectory . '/translations';
 
     $this->generatedTestFiles = FALSE;
 
diff --git a/core/modules/simpletest/src/Tests/BrokenSetUpTest.php b/core/modules/simpletest/src/Tests/BrokenSetUpTest.php
index 239a022..6621545 100644
--- a/core/modules/simpletest/src/Tests/BrokenSetUpTest.php
+++ b/core/modules/simpletest/src/Tests/BrokenSetUpTest.php
@@ -41,7 +41,7 @@ protected function setUp() {
     if (!$this->isInChildSite()) {
       parent::setUp();
 
-      $this->sharedTriggerFile = $this->public_files_directory . '/trigger';
+      $this->sharedTriggerFile = $this->publicFilesDirectory . '/trigger';
 
       // Create and log in user.
       $admin_user = $this->drupalCreateUser(array('administer unit tests'));
diff --git a/core/modules/simpletest/src/Tests/InstallationProfileModuleTestsTest.php b/core/modules/simpletest/src/Tests/InstallationProfileModuleTestsTest.php
index 43b1c74..424469a 100644
--- a/core/modules/simpletest/src/Tests/InstallationProfileModuleTestsTest.php
+++ b/core/modules/simpletest/src/Tests/InstallationProfileModuleTestsTest.php
@@ -24,6 +24,13 @@ class InstallationProfileModuleTestsTest extends WebTestBase {
   public static $modules = array('simpletest');
 
   /**
+   * An administrative user with permission to adminsiter unit tests.
+   *
+   * @var \Drupal\user\UserInterface
+   */
+  protected $adminUser;
+
+  /**
    * Use the Testing profile.
    *
    * The Testing profile contains drupal_system_listing_compatible_test.test,
@@ -40,8 +47,8 @@ class InstallationProfileModuleTestsTest extends WebTestBase {
   protected function setUp() {
     parent::setUp();
 
-    $this->admin_user = $this->drupalCreateUser(array('administer unit tests'));
-    $this->drupalLogin($this->admin_user);
+    $this->adminUser = $this->drupalCreateUser(array('administer unit tests'));
+    $this->drupalLogin($this->adminUser);
   }
 
   /**
diff --git a/core/modules/simpletest/src/Tests/OtherInstallationProfileTestsTest.php b/core/modules/simpletest/src/Tests/OtherInstallationProfileTestsTest.php
index 6e6e01b..9cfbfff 100644
--- a/core/modules/simpletest/src/Tests/OtherInstallationProfileTestsTest.php
+++ b/core/modules/simpletest/src/Tests/OtherInstallationProfileTestsTest.php
@@ -38,11 +38,18 @@ class OtherInstallationProfileTestsTest extends WebTestBase {
    */
   protected $profile = 'minimal';
 
+  /**
+   * An administrative user with permission to administer unit tests.
+   *
+   * @var \Drupal\user\UserInterface
+   */
+  protected $adminUser;
+
   protected function setUp() {
     parent::setUp();
 
-    $this->admin_user = $this->drupalCreateUser(array('administer unit tests'));
-    $this->drupalLogin($this->admin_user);
+    $this->adminUser = $this->drupalCreateUser(array('administer unit tests'));
+    $this->drupalLogin($this->adminUser);
   }
 
   /**
diff --git a/core/modules/simpletest/src/Tests/SimpleTestTest.php b/core/modules/simpletest/src/Tests/SimpleTestTest.php
index d2949a6..15693d2 100644
--- a/core/modules/simpletest/src/Tests/SimpleTestTest.php
+++ b/core/modules/simpletest/src/Tests/SimpleTestTest.php
@@ -38,7 +38,7 @@ class SimpleTestTest extends WebTestBase {
    *
    * Used to ensure they are incrementing.
    */
-  protected $test_ids = array();
+  protected $testIds = array();
 
   /**
    * Translated fail message.
@@ -53,6 +53,20 @@ class SimpleTestTest extends WebTestBase {
    */
   private $passMessage = '';
 
+  /**
+   * A valid and recognized permission.
+   *
+   * @var string
+   */
+  protected $validPermission;
+
+  /**
+   * An invalid or unrecognized permission.
+   *
+   * @var string
+   */
+  protected $invalidPermission;
+
   protected function setUp() {
     if (!$this->isInChildSite()) {
       $php = <<<'EOD'
@@ -103,8 +117,8 @@ class: Drupal\Core\Cache\MemoryBackendFactory
   function testWebTestRunner() {
     $this->passMessage = t('SimpleTest pass.');
     $this->failMessage = t('SimpleTest fail.');
-    $this->valid_permission = 'access administration pages';
-    $this->invalid_permission = 'invalid permission';
+    $this->validPermission = 'access administration pages';
+    $this->invalidPermission = 'invalid permission';
 
     if ($this->isInChildSite()) {
       // Only run following code if this test is running itself through a CURL
@@ -128,7 +142,7 @@ function testWebTestRunner() {
 
       // Regression test for #290316.
       // Check that test_id is incrementing.
-      $this->assertTrue($this->test_ids[0] != $this->test_ids[1], 'Test ID is incrementing.');
+      $this->assertTrue($this->testIds[0] != $this->testIds[1], 'Test ID is incrementing.');
     }
   }
 
@@ -162,10 +176,10 @@ function stubTest() {
 
     // This causes the second to fourth of the fifteen passes asserted in
     // confirmStubResults().
-    $user = $this->drupalCreateUser(array($this->valid_permission), 'SimpleTestTest');
+    $user = $this->drupalCreateUser(array($this->validPermission), 'SimpleTestTest');
 
     // This causes the fifth of the five fails asserted in confirmStubResults().
-    $this->drupalCreateUser(array($this->invalid_permission));
+    $this->drupalCreateUser(array($this->invalidPermission));
 
     // Test logging in as a user.
     // This causes the fifth to ninth of the fifteen passes asserted in
@@ -215,8 +229,8 @@ function confirmStubTestResults() {
     $this->assertAssertion($this->passMessage, 'Other', 'Pass', 'SimpleTestTest.php', 'Drupal\simpletest\Tests\SimpleTestTest->stubTest()');
     $this->assertAssertion($this->failMessage, 'Other', 'Fail', 'SimpleTestTest.php', 'Drupal\simpletest\Tests\SimpleTestTest->stubTest()');
 
-    $this->assertAssertion(t('Created permissions: @perms', array('@perms' => $this->valid_permission)), 'Role', 'Pass', 'SimpleTestTest.php', 'Drupal\simpletest\Tests\SimpleTestTest->stubTest()');
-    $this->assertAssertion(t('Invalid permission %permission.', array('%permission' => $this->invalid_permission)), 'Role', 'Fail', 'SimpleTestTest.php', 'Drupal\simpletest\Tests\SimpleTestTest->stubTest()');
+    $this->assertAssertion(t('Created permissions: @perms', array('@perms' => $this->validPermission)), 'Role', 'Pass', 'SimpleTestTest.php', 'Drupal\simpletest\Tests\SimpleTestTest->stubTest()');
+    $this->assertAssertion(t('Invalid permission %permission.', array('%permission' => $this->invalidPermission)), 'Role', 'Fail', 'SimpleTestTest.php', 'Drupal\simpletest\Tests\SimpleTestTest->stubTest()');
 
     // Check that the user was logged in successfully.
     $this->assertAssertion('User SimpleTestTest successfully logged in.', 'User login', 'Pass', 'SimpleTestTest.php', 'Drupal\simpletest\Tests\SimpleTestTest->stubTest()');
@@ -237,7 +251,7 @@ function confirmStubTestResults() {
 
     $this->assertEqual('15 passes, 3 fails, 2 exceptions, 3 debug messages', $this->childTestResults['summary']);
 
-    $this->test_ids[] = $test_id = $this->getTestIdFromResults();
+    $this->testIds[] = $test_id = $this->getTestIdFromResults();
     $this->assertTrue($test_id, 'Found test ID in results.');
   }
 
diff --git a/core/modules/simpletest/src/WebTestBase.php b/core/modules/simpletest/src/WebTestBase.php
index 9350dfa..390aef4 100644
--- a/core/modules/simpletest/src/WebTestBase.php
+++ b/core/modules/simpletest/src/WebTestBase.php
@@ -68,6 +68,13 @@
   protected $headers;
 
   /**
+   * The cookies of the page currently loaded in the internal browser.
+   *
+   * @var array
+   */
+  protected $cookies;
+
+  /**
    * Indicates that headers should be dumped if verbose output is enabled.
    *
    * Headers are dumped to verbose by drupalGet(), drupalHead(), and
@@ -85,6 +92,14 @@
   protected $loggedInUser = FALSE;
 
   /**
+   * The "#1" admin user.
+   *
+   * @var \Drupal\Core\Session\AccountInterface
+   */
+  protected $rootUser;
+
+
+  /**
    * The current cookie file used by cURL.
    *
    * We do not reuse the cookies in further runs, so we do not need a file
@@ -101,6 +116,13 @@
   protected $additionalCurlOptions = array();
 
   /**
+   * The original batch, before it was changed for testing purposes.
+   *
+   * @var array
+   */
+  protected $originalBatch;
+
+  /**
    * The original user, before it was changed to a clean uid = 1 for testing.
    *
    * @var object
@@ -127,12 +149,12 @@
   /**
    * The current session name, if available.
    */
-  protected $session_name = NULL;
+  protected $sessionName = NULL;
 
   /**
    * The current session ID, if available.
    */
-  protected $session_id = NULL;
+  protected $sessionId = NULL;
 
   /**
    * Whether the files were copied to the test files directory.
@@ -147,7 +169,7 @@
   /**
    * The number of redirects followed during the handling of a request.
    */
-  protected $redirect_count;
+  protected $redirectCount;
 
   /**
    * The kernel used in this test.
@@ -678,8 +700,8 @@ protected function drupalLogin(AccountInterface $account) {
     $this->drupalPostForm('user/login', $edit, t('Log in'));
 
     // @see WebTestBase::drupalUserIsLoggedIn()
-    if (isset($this->session_id)) {
-      $account->session_id = $this->session_id;
+    if (isset($this->sessionId)) {
+      $account->session_id = $this->sessionId;
     }
     $pass = $this->assert($this->drupalUserIsLoggedIn($account), format_string('User %name successfully logged in.', array('%name' => $account->getUsername())), 'User login');
     if ($pass) {
@@ -732,7 +754,7 @@ protected function drupalLogout() {
    *   The name of the session cookie.
    */
   public function getSessionName() {
-    return $this->session_name;
+    return $this->sessionName;
   }
 
   /**
@@ -759,7 +781,7 @@ protected function setUp() {
     $this->originalBatch = batch_get();
 
     // Define information about the user 1 account.
-    $this->root_user = new UserSession(array(
+    $this->rootUser = new UserSession(array(
       'uid' => 1,
       'name' => 'admin',
       'mail' => 'admin@example.com',
@@ -770,7 +792,7 @@ protected function setUp() {
     // proper session cookies were set on a response. Because the child site
     // uses the same session name as the test runner, it is necessary to make
     // that available to test-methods.
-    $this->session_name = $this->originalSessionName;
+    $this->sessionName = $this->originalSessionName;
 
     // Reset the static batch to remove Simpletest's batch operations.
     $batch = &batch_get();
@@ -791,7 +813,7 @@ protected function setUp() {
     // @see system_requirements()
     // @see TestBase::prepareEnvironment()
     $settings['settings']['file_public_path'] = (object) array(
-      'value' => $this->public_files_directory,
+      'value' => $this->publicFilesDirectory,
       'required' => TRUE,
     );
     // Save the original site directory path, so that extensions in the
@@ -871,11 +893,11 @@ protected function setUp() {
     // While these could be preset/enforced in settings.php like the public
     // files directory above, some tests expect them to be configurable in the
     // UI. If declared in settings.php, they would no longer be configurable.
-    file_prepare_directory($this->private_files_directory, FILE_CREATE_DIRECTORY);
-    file_prepare_directory($this->temp_files_directory, FILE_CREATE_DIRECTORY);
+    file_prepare_directory($this->privateFilesDirectory, FILE_CREATE_DIRECTORY);
+    file_prepare_directory($this->tempFilesDirectory, FILE_CREATE_DIRECTORY);
     $config->get('system.file')
-      ->set('path.private', $this->private_files_directory)
-      ->set('path.temporary', $this->temp_files_directory)
+      ->set('path.private', $this->privateFilesDirectory)
+      ->set('path.temporary', $this->tempFilesDirectory)
       ->save();
 
     // Manually configure the test mail collector implementation to prevent
@@ -969,11 +991,11 @@ protected function installParameters() {
           'site_name' => 'Drupal',
           'site_mail' => 'simpletest@example.com',
           'account' => array(
-            'name' => $this->root_user->name,
-            'mail' => $this->root_user->getEmail(),
+            'name' => $this->rootUser->name,
+            'mail' => $this->rootUser->getEmail(),
             'pass' => array(
-              'pass1' => $this->root_user->pass_raw,
-              'pass2' => $this->root_user->pass_raw,
+              'pass1' => $this->rootUser->pass_raw,
+              'pass2' => $this->rootUser->pass_raw,
             ),
           ),
           // \Drupal\Core\Render\Element\Checkboxes::valueCallback() requires
@@ -1210,7 +1232,7 @@ protected function curlInitialize() {
       // Some versions/configurations of cURL break on a NULL cookie jar, so
       // supply a real file.
       if (empty($this->cookieFile)) {
-        $this->cookieFile = $this->public_files_directory . '/cookie.jar';
+        $this->cookieFile = $this->publicFilesDirectory . '/cookie.jar';
       }
 
       $curl_options = array(
@@ -1331,9 +1353,9 @@ protected function curlExec($curl_options, $redirect = FALSE) {
 
     if (!$redirect) {
       // Reset headers, the session ID and the redirect counter.
-      $this->session_id = NULL;
+      $this->sessionId = NULL;
       $this->headers = array();
-      $this->redirect_count = 0;
+      $this->redirectCount = 0;
     }
 
     $content = curl_exec($this->curlHandle);
@@ -1344,9 +1366,9 @@ protected function curlExec($curl_options, $redirect = FALSE) {
     // to prevent fragments being sent to the web server as part
     // of the request.
     // TODO: Remove this for Drupal 8, since fixed in curl 7.20.0.
-    if (in_array($status, array(300, 301, 302, 303, 305, 307)) && $this->redirect_count < $this->maximumRedirects) {
+    if (in_array($status, array(300, 301, 302, 303, 305, 307)) && $this->redirectCount < $this->maximumRedirects) {
       if ($this->drupalGetHeader('location')) {
-        $this->redirect_count++;
+        $this->redirectCount++;
         $curl_options = array();
         $curl_options[CURLOPT_URL] = $this->drupalGetHeader('location');
         $curl_options[CURLOPT_HTTPGET] = TRUE;
@@ -1405,12 +1427,12 @@ protected function curlHeaderCallback($curlHandler, $header) {
       $parts = array_map('trim', explode(';', $matches[2]));
       $value = array_shift($parts);
       $this->cookies[$name] = array('value' => $value, 'secure' => in_array('secure', $parts));
-      if ($name == $this->session_name) {
+      if ($name == $this->sessionName) {
         if ($value != 'deleted') {
-          $this->session_id = $value;
+          $this->sessionId = $value;
         }
         else {
-          $this->session_id = NULL;
+          $this->sessionId = NULL;
         }
       }
     }
diff --git a/core/modules/system/src/Tests/Session/SessionTest.php b/core/modules/system/src/Tests/Session/SessionTest.php
index ae7fa8d..20bb4ef 100644
--- a/core/modules/system/src/Tests/Session/SessionTest.php
+++ b/core/modules/system/src/Tests/Session/SessionTest.php
@@ -285,10 +285,10 @@ function sessionReset($uid = 0) {
    */
   function assertSessionCookie($sent) {
     if ($sent) {
-      $this->assertNotNull($this->session_id, 'Session cookie was sent.');
+      $this->assertNotNull($this->sessionId, 'Session cookie was sent.');
     }
     else {
-      $this->assertNull($this->session_id, 'Session cookie was not sent.');
+      $this->assertNull($this->sessionId, 'Session cookie was not sent.');
     }
   }
 
