diff --git a/core/modules/simpletest/lib/Drupal/simpletest/Tests/SimpleTestTest.php b/core/modules/simpletest/lib/Drupal/simpletest/Tests/SimpleTestTest.php
index 11de754..180c58f 100644
--- a/core/modules/simpletest/lib/Drupal/simpletest/Tests/SimpleTestTest.php
+++ b/core/modules/simpletest/lib/Drupal/simpletest/Tests/SimpleTestTest.php
@@ -54,7 +54,6 @@ function setUp() {
    * Test the internal browsers functionality.
    */
   function testInternalBrowser() {
-    global $conf;
     if (!$this->inCURL()) {
       // Retrieve the test page and check its title and headers.
       $this->drupalGet('test-page');
@@ -64,8 +63,11 @@ function testInternalBrowser() {
       )));
       $this->assertNoTitle('Foo');
 
+      $old_user_id = $this->container->get('current_user')->id();
       $user = $this->drupalCreateUser();
       $this->drupalLogin($user);
+      // Check that current user service updated.
+      $this->assertNotEqual($old_user_id, $this->container->get('current_user')->id(), 'Current user service updated.');
       $headers = $this->drupalGetHeaders(TRUE);
       $this->assertEqual(count($headers), 2, 'There was one intermediate request.');
       $this->assertTrue(strpos($headers[0][':status'], '302') !== FALSE, 'Intermediate response code was 302.');
@@ -76,6 +78,8 @@ function testInternalBrowser() {
 
       // Test the maximum redirection option.
       $this->drupalLogout();
+      // Check that current user service updated to anonymous user.
+      $this->assertEqual(0, $this->container->get('current_user')->id(), 'Current user service updated.');
       $edit = array(
         'name' => $user->getUsername(),
         'pass' => $user->pass_raw
@@ -94,7 +98,6 @@ function testInternalBrowser() {
       global $base_url;
       $this->drupalGet(url($base_url . '/core/install.php', array('external' => TRUE, 'absolute' => TRUE)));
       $this->assertResponse(403, 'Cannot access install.php.');
-
     }
   }
 
