diff --git a/core/modules/menu_ui/src/Tests/MenuLanguageTest.php b/core/modules/menu_ui/src/Tests/MenuLanguageTest.php
index 3c920b7..f739544 100644
--- a/core/modules/menu_ui/src/Tests/MenuLanguageTest.php
+++ b/core/modules/menu_ui/src/Tests/MenuLanguageTest.php
@@ -27,15 +27,10 @@ class MenuLanguageTest extends MenuWebTestBase {
    */
   public static $modules = array('language');
 
-  protected $admin_user;
-  protected $menu;
-
   protected function setUp() {
     parent::setUp();
 
-    // Create user.
-    $this->admin_user = $this->drupalCreateUser(array('access administration pages', 'administer menu'));
-    $this->drupalLogin($this->admin_user);
+    $this->drupalLogin($this->drupalCreateUser(['access administration pages', 'administer menu']));
 
     // Add some custom languages.
     foreach (array('aa', 'bb', 'cc', 'cs') as $language_code) {
diff --git a/core/modules/menu_ui/src/Tests/MenuNodeTest.php b/core/modules/menu_ui/src/Tests/MenuNodeTest.php
index 99798d6..c6996ba 100644
--- a/core/modules/menu_ui/src/Tests/MenuNodeTest.php
+++ b/core/modules/menu_ui/src/Tests/MenuNodeTest.php
@@ -22,24 +22,23 @@ class MenuNodeTest extends WebTestBase {
    *
    * @var array
    */
-  public static $modules = array('menu_ui', 'test_page_test', 'node', 'block');
+  public static $modules = ['menu_ui', 'test_page_test', 'node', 'block'];
 
   protected function setUp() {
     parent::setUp();
 
     $this->drupalPlaceBlock('system_menu_block:main');
 
-    $this->drupalCreateContentType(array('type' => 'page', 'name' => 'Basic page'));
+    $this->drupalCreateContentType(['type' => 'page', 'name' => 'Basic page']);
 
-    $this->admin_user = $this->drupalCreateUser(array(
+    $this->drupalLogin($this->drupalCreateUser([
       'access administration pages',
       'administer content types',
       'administer menu',
       'create page content',
       'edit any page content',
       'delete any page content',
-    ));
-    $this->drupalLogin($this->admin_user);
+    ]));
   }
 
   /**
diff --git a/core/modules/menu_ui/src/Tests/MenuTest.php b/core/modules/menu_ui/src/Tests/MenuTest.php
index 098ed0a..cf250b2 100644
--- a/core/modules/menu_ui/src/Tests/MenuTest.php
+++ b/core/modules/menu_ui/src/Tests/MenuTest.php
@@ -33,16 +33,16 @@ class MenuTest extends MenuWebTestBase {
   /**
    * A user with administration rights.
    *
-   * @var \Drupal\user\Entity\User
+   * @var \Drupal\user\UserInterface
    */
-  protected $admin_user;
+  protected $adminUser;
 
   /**
    * An authenticated user.
    *
-   * @var \Drupal\user\Entity\User
+   * @var \Drupal\user\UserInterface
    */
-  protected $authenticated_user;
+  protected $authenticatedUser;
 
   /**
    * A test menu.
@@ -64,8 +64,8 @@ protected function setUp() {
     $this->drupalCreateContentType(array('type' => 'article', 'name' => 'Article'));
 
     // Create users.
-    $this->admin_user = $this->drupalCreateUser(array('access administration pages', 'administer blocks', 'administer menu', 'create article content'));
-    $this->authenticated_user = $this->drupalCreateUser(array());
+    $this->adminUser = $this->drupalCreateUser(['access administration pages', 'administer blocks', 'administer menu', 'create article content']);
+    $this->authenticatedUser = $this->drupalCreateUser([]);
   }
 
   /**
@@ -73,7 +73,7 @@ protected function setUp() {
    */
   function testMenu() {
     // Login the user.
-    $this->drupalLogin($this->admin_user);
+    $this->drupalLogin($this->adminUser);
     $this->items = array();
 
     $this->menu = $this->addCustomMenu();
@@ -91,7 +91,7 @@ function testMenu() {
     $this->assertIdentical($before_count, $after_count, 'MenuLinkManager::rebuild() does not add more links');
     // Do standard user tests.
     // Login the user.
-    $this->drupalLogin($this->authenticated_user);
+    $this->drupalLogin($this->authenticatedUser);
     $this->verifyAccess(403);
 
     foreach ($this->items as $item) {
@@ -101,7 +101,7 @@ function testMenu() {
     }
 
     // Login the administrator.
-    $this->drupalLogin($this->admin_user);
+    $this->drupalLogin($this->adminUser);
 
     // Delete menu links.
     foreach ($this->items as $item) {
@@ -447,7 +447,7 @@ protected function doMenuLinkFormDefaultsTest() {
    * Adds and removes a menu link with a query string and fragment.
    */
   function testMenuQueryAndFragment() {
-    $this->drupalLogin($this->admin_user);
+    $this->drupalLogin($this->adminUser);
 
     // Make a path with query and fragment on.
     $path = 'test-page?arg1=value1&arg2=value2';
@@ -480,7 +480,7 @@ function testMenuQueryAndFragment() {
    * Tests renaming the built-in menu.
    */
   function testSystemMenuRename() {
-    $this->drupalLogin($this->admin_user);
+    $this->drupalLogin($this->adminUser);
     $edit = array(
       'label' => $this->randomMachineName(16),
     );
@@ -509,7 +509,7 @@ function testUnpublishedNodeMenuItem() {
     // Test that a user with 'administer menu' but without 'bypass node access'
     // cannot see the menu item.
     $this->drupalLogout();
-    $this->drupalLogin($this->admin_user);
+    $this->drupalLogin($this->adminUser);
     $this->drupalGet('admin/structure/menu/manage/' . $item->getMenuName());
     $this->assertNoText($item->getTitle(), "Menu link pointing to unpublished node is only visible to users with 'bypass node access' permission");
   }
@@ -553,7 +553,7 @@ public function testBlockContextualLinks() {
    *   Menu name. Defaults to 'tools'.
    * @param bool $expanded
    *   Whether or not this menu link is expanded. Setting this to TRUE should
-   *   test whether it works when we do the authenticated_user tests. Defaults
+   *   test whether it works when we do the authenticatedUser tests. Defaults
    *   to FALSE.
    * @param string $weight
    *  Menu weight. Defaults to 0.
@@ -789,7 +789,7 @@ public function testMenuParentsJsAccess() {
 
     // Do standard user tests.
     // Login the user.
-    $this->drupalLogin($this->authenticated_user);
+    $this->drupalLogin($this->authenticatedUser);
     $this->drupalGetAJAX('admin/structure/menu/parents');
     $this->assertResponse(403);
   }
