From 63c85acafa17de88e58f39c1a6222d3f755c1495 Mon Sep 17 00:00:00 2001
From: Alex Pott <alex.a.pott@googlemail.com>
Date: Fri, 31 Jul 2020 14:38:45 +0100
Subject: [PATCH] Issue #3156040 by Hardik_Patel_12, kiamlaluno,
 siddhant.bhosale, paulocs: Avoid initializing a local variable to an empty
 array before adding items to that array

---
 core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php | 2 --
 1 file changed, 2 deletions(-)

diff --git a/core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php b/core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php
index 69ede129af76..9ec3e281af90 100644
--- a/core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php
+++ b/core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php
@@ -374,7 +374,6 @@ public function testCheckNamedRouteWithUpcastedValues() {
       ->with('test_route_1')
       ->will($this->returnValue($route));
 
-    $map = [];
     $map[] = ['test_route_1', ['value' => 'example'], '/test-route-1/example'];
 
     $this->paramConverter = $this->createMock('Drupal\Core\ParamConverter\ParamConverterManagerInterface');
@@ -423,7 +422,6 @@ public function testCheckNamedRouteWithDefaultValue() {
       ->with('test_route_1')
       ->will($this->returnValue($route));
 
-    $map = [];
     $map[] = ['test_route_1', ['value' => 'example'], '/test-route-1/example'];
 
     $this->paramConverter = $this->createMock('Drupal\Core\ParamConverter\ParamConverterManagerInterface');
-- 
GitLab