diff --git a/core/tests/Drupal/KernelTests/Core/Routing/ContentNegotiationRoutingTest.php b/core/tests/Drupal/KernelTests/Core/Routing/ContentNegotiationRoutingTest.php
index 052e74f35b..8091ae2b45 100644
--- a/core/tests/Drupal/KernelTests/Core/Routing/ContentNegotiationRoutingTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Routing/ContentNegotiationRoutingTest.php
@@ -97,7 +97,7 @@ public function testContentRouting() {
       // Verbose message since simpletest doesn't let us provide a message and
       // see the error.
       $this->assertTrue(TRUE, $message);
-      $this->assertEqual($response->getStatusCode(), Response::HTTP_OK);
+      $this->assertEquals($response->getStatusCode(), Response::HTTP_OK);
       $this->assertTrue(strpos($response->headers->get('Content-type'), $content_type) !== FALSE);
     }
   }
@@ -134,7 +134,7 @@ public function testFullNegotiation() {
       // Verbose message since simpletest doesn't let us provide a message and
       // see the error.
       $this->pass($message);
-      $this->assertEqual($response->getStatusCode(), Response::HTTP_OK);
+      $this->assertEquals($response->getStatusCode(), Response::HTTP_OK);
     }
   }
 
diff --git a/core/tests/Drupal/KernelTests/Core/Routing/ExceptionHandlingTest.php b/core/tests/Drupal/KernelTests/Core/Routing/ExceptionHandlingTest.php
index a791454f72..a1e8c40d6c 100644
--- a/core/tests/Drupal/KernelTests/Core/Routing/ExceptionHandlingTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Routing/ExceptionHandlingTest.php
@@ -38,7 +38,7 @@ public function test405() {
     $kernel = \Drupal::getContainer()->get('http_kernel');
     $response = $kernel->handle($request);
 
-    $this->assertEqual(Response::HTTP_METHOD_NOT_ALLOWED, $response->getStatusCode());
+    $this->assertEquals(Response::HTTP_METHOD_NOT_ALLOWED, $response->getStatusCode());
   }
 
   /**
@@ -53,9 +53,9 @@ public function testJson403() {
     $kernel = \Drupal::getContainer()->get('http_kernel');
     $response = $kernel->handle($request);
 
-    $this->assertEqual($response->getStatusCode(), Response::HTTP_FORBIDDEN);
-    $this->assertEqual($response->headers->get('Content-type'), 'application/json');
-    $this->assertEqual('{"message":""}', $response->getContent());
+    $this->assertEquals($response->getStatusCode(), Response::HTTP_FORBIDDEN);
+    $this->assertEquals($response->headers->get('Content-type'), 'application/json');
+    $this->assertEquals('{"message":""}', $response->getContent());
   }
 
   /**
@@ -70,9 +70,9 @@ public function testJson404() {
     $kernel = \Drupal::getContainer()->get('http_kernel');
     $response = $kernel->handle($request);
 
-    $this->assertEqual($response->getStatusCode(), Response::HTTP_NOT_FOUND);
-    $this->assertEqual($response->headers->get('Content-type'), 'application/json');
-    $this->assertEqual('{"message":"No route found for \\u0022GET \\/not-found\\u0022"}', $response->getContent());
+    $this->assertEquals($response->getStatusCode(), Response::HTTP_NOT_FOUND);
+    $this->assertEquals($response->headers->get('Content-type'), 'application/json');
+    $this->assertEquals('{"message":"No route found for \\u0022GET \\/not-found\\u0022"}', $response->getContent());
   }
 
   /**
@@ -86,8 +86,8 @@ public function testHtml403() {
     $kernel = \Drupal::getContainer()->get('http_kernel');
     $response = $kernel->handle($request)->prepare($request);
 
-    $this->assertEqual($response->getStatusCode(), Response::HTTP_FORBIDDEN);
-    $this->assertEqual($response->headers->get('Content-type'), 'text/html; charset=UTF-8');
+    $this->assertEquals($response->getStatusCode(), Response::HTTP_FORBIDDEN);
+    $this->assertEquals($response->headers->get('Content-type'), 'text/html; charset=UTF-8');
   }
 
   /**
@@ -101,8 +101,8 @@ public function testHtml404() {
     $kernel = \Drupal::getContainer()->get('http_kernel');
     $response = $kernel->handle($request)->prepare($request);
 
-    $this->assertEqual($response->getStatusCode(), Response::HTTP_NOT_FOUND);
-    $this->assertEqual($response->headers->get('Content-type'), 'text/html; charset=UTF-8');
+    $this->assertEquals($response->getStatusCode(), Response::HTTP_NOT_FOUND);
+    $this->assertEquals($response->headers->get('Content-type'), 'text/html; charset=UTF-8');
   }
 
   /**
@@ -154,8 +154,8 @@ public function testBacktraceEscaping() {
     /** @var \Symfony\Component\HttpKernel\HttpKernelInterface $kernel */
     $kernel = \Drupal::getContainer()->get('http_kernel');
     $response = $kernel->handle($request)->prepare($request);
-    $this->assertEqual($response->getStatusCode(), Response::HTTP_INTERNAL_SERVER_ERROR);
-    $this->assertEqual($response->headers->get('Content-type'), 'text/plain; charset=UTF-8');
+    $this->assertEquals($response->getStatusCode(), Response::HTTP_INTERNAL_SERVER_ERROR);
+    $this->assertEquals($response->headers->get('Content-type'), 'text/plain; charset=UTF-8');
 
     // Test both that the backtrace is properly escaped, and that the unescaped
     // string is not output at all.
@@ -177,8 +177,8 @@ public function testExceptionEscaping() {
     /** @var \Symfony\Component\HttpKernel\HttpKernelInterface $kernel */
     $kernel = \Drupal::getContainer()->get('http_kernel');
     $response = $kernel->handle($request)->prepare($request);
-    $this->assertEqual($response->getStatusCode(), Response::HTTP_INTERNAL_SERVER_ERROR);
-    $this->assertEqual($response->headers->get('Content-type'), 'text/plain; charset=UTF-8');
+    $this->assertEquals($response->getStatusCode(), Response::HTTP_INTERNAL_SERVER_ERROR);
+    $this->assertEquals($response->headers->get('Content-type'), 'text/plain; charset=UTF-8');
 
     // Test message is properly escaped, and that the unescaped string is not
     // output at all.
@@ -195,7 +195,7 @@ public function testExceptionEscaping() {
     // contained in the output would not matter, but because it is output by the
     // final exception subscriber, it is printed as partial HTML, and hence
     // escaped.
-    $this->assertEqual($response->headers->get('Content-type'), 'text/plain; charset=UTF-8');
+    $this->assertEquals($response->headers->get('Content-type'), 'text/plain; charset=UTF-8');
     $this->assertStringStartsWith('The website encountered an unexpected error. Please try again later.</br></br><em class="placeholder">Symfony\Component\HttpKernel\Exception\NotAcceptableHttpException</em>: Not acceptable format: json&lt;script&gt;alert(123);&lt;/script&gt; in <em class="placeholder">', $response->getContent());
   }
 
diff --git a/core/tests/Drupal/KernelTests/Core/Routing/MatcherDumperTest.php b/core/tests/Drupal/KernelTests/Core/Routing/MatcherDumperTest.php
index 1428fde95f..9467fd25bf 100644
--- a/core/tests/Drupal/KernelTests/Core/Routing/MatcherDumperTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Routing/MatcherDumperTest.php
@@ -69,7 +69,7 @@ public function testAddRoutes() {
     $collection_routes = $collection->all();
 
     foreach ($dumper_routes as $name => $route) {
-      $this->assertEqual($route->getPath(), $collection_routes[$name]->getPath(), 'Routes match');
+      $this->assertEquals($route->getPath(), $collection_routes[$name]->getPath(), 'Routes match');
     }
   }
 
@@ -131,10 +131,10 @@ public function testDump() {
 
     $loaded_route = unserialize($record->route);
 
-    $this->assertEqual($record->name, 'test_route', 'Dumped route has correct name.');
-    $this->assertEqual($record->path, '/test/{my}/path', 'Dumped route has correct pattern.');
-    $this->assertEqual($record->pattern_outline, '/test/%/path', 'Dumped route has correct pattern outline.');
-    $this->assertEqual($record->fit, 5 /* 101 in binary */, 'Dumped route has correct fit.');
+    $this->assertEquals($record->name, 'test_route', 'Dumped route has correct name.');
+    $this->assertEquals($record->path, '/test/{my}/path', 'Dumped route has correct pattern.');
+    $this->assertEquals($record->pattern_outline, '/test/%/path', 'Dumped route has correct pattern outline.');
+    $this->assertEquals($record->fit, 5 /* 101 in binary */, 'Dumped route has correct fit.');
     $this->assertTrue($loaded_route instanceof Route, 'Route object retrieved successfully.');
   }
 
@@ -164,7 +164,7 @@ public function testMenuMasksGeneration() {
       bindec('111'),
       bindec('101'),
     ];
-    $this->assertEqual($this->state->get('routing.menu_masks.test_routes'), $expected);
+    $this->assertEquals($this->state->get('routing.menu_masks.test_routes'), $expected);
   }
 
 }
diff --git a/core/tests/Drupal/KernelTests/Core/Routing/RouteProviderTest.php b/core/tests/Drupal/KernelTests/Core/Routing/RouteProviderTest.php
index ed59f2f0ff..0735b9a6a5 100644
--- a/core/tests/Drupal/KernelTests/Core/Routing/RouteProviderTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Routing/RouteProviderTest.php
@@ -139,7 +139,7 @@ public function testCandidateOutlines() {
   public function testEmptyPathCandidatesOutlines() {
     $provider = new TestRouteProvider(Database::getConnection(), $this->state, $this->currentPath, $this->cache, $this->pathProcessor, $this->cacheTagsInvalidator, 'test_routes');
     $candidates = $provider->getCandidateOutlines([]);
-    $this->assertEqual(count($candidates), 0, 'Empty parts should return no candidates.');
+    $this->assertEquals(count($candidates), 0, 'Empty parts should return no candidates.');
   }
 
   /**
@@ -162,7 +162,7 @@ public function testExactPathMatch() {
     $routes = $provider->getRouteCollectionForRequest($request);
 
     foreach ($routes as $route) {
-      $this->assertEqual($route->getPath(), $path, 'Found path has correct pattern');
+      $this->assertEquals($route->getPath(), $path, 'Found path has correct pattern');
     }
   }
 
@@ -187,10 +187,10 @@ public function testOutlinePathMatch() {
 
     // All of the matching paths have the correct pattern.
     foreach ($routes as $route) {
-      $this->assertEqual($route->compile()->getPatternOutline(), '/path/%/one', 'Found path has correct pattern');
+      $this->assertEquals($route->compile()->getPatternOutline(), '/path/%/one', 'Found path has correct pattern');
     }
 
-    $this->assertEqual(count($routes), 2, 'The correct number of routes was found.');
+    $this->assertEquals(count($routes), 2, 'The correct number of routes was found.');
     $this->assertNotNull($routes->get('route_a'), 'The first matching route was found.');
     $this->assertNotNull($routes->get('route_b'), 'The second matching route was not found.');
   }
@@ -317,10 +317,10 @@ public function testOutlinePathMatchTrailingSlash() {
 
     // All of the matching paths have the correct pattern.
     foreach ($routes as $route) {
-      $this->assertEqual($route->compile()->getPatternOutline(), '/path/%/one', 'Found path has correct pattern');
+      $this->assertEquals($route->compile()->getPatternOutline(), '/path/%/one', 'Found path has correct pattern');
     }
 
-    $this->assertEqual(count($routes), 2, 'The correct number of routes was found.');
+    $this->assertEquals(count($routes), 2, 'The correct number of routes was found.');
     $this->assertNotNull($routes->get('route_a'), 'The first matching route was found.');
     $this->assertNotNull($routes->get('route_b'), 'The second matching route was not found.');
   }
@@ -352,10 +352,10 @@ public function testOutlinePathMatchDefaults() {
 
       // All of the matching paths have the correct pattern.
       foreach ($routes as $route) {
-        $this->assertEqual($route->compile()->getPatternOutline(), '/some/path', 'Found path has correct pattern');
+        $this->assertEquals($route->compile()->getPatternOutline(), '/some/path', 'Found path has correct pattern');
       }
 
-      $this->assertEqual(count($routes), 1, 'The correct number of routes was found.');
+      $this->assertEquals(count($routes), 1, 'The correct number of routes was found.');
       $this->assertNotNull($routes->get('poink'), 'The first matching route was found.');
     }
     catch (ResourceNotFoundException $e) {
@@ -391,10 +391,10 @@ public function testOutlinePathMatchDefaultsCollision() {
 
       // All of the matching paths have the correct pattern.
       foreach ($routes as $route) {
-        $this->assertEqual($route->compile()->getPatternOutline(), '/some/path', 'Found path has correct pattern');
+        $this->assertEquals($route->compile()->getPatternOutline(), '/some/path', 'Found path has correct pattern');
       }
 
-      $this->assertEqual(count($routes), 1, 'The correct number of routes was found.');
+      $this->assertEquals(count($routes), 1, 'The correct number of routes was found.');
       $this->assertNotNull($routes->get('poink'), 'The first matching route was found.');
     }
     catch (ResourceNotFoundException $e) {
@@ -430,8 +430,8 @@ public function testOutlinePathMatchDefaultsCollision2() {
       $routes = $provider->getRouteCollectionForRequest($request);
       $routes_array = $routes->all();
 
-      $this->assertEqual(count($routes), 2, 'The correct number of routes was found.');
-      $this->assertEqual(['narf', 'poink'], array_keys($routes_array), 'Ensure the fitness was taken into account.');
+      $this->assertEquals(count($routes), 2, 'The correct number of routes was found.');
+      $this->assertEquals(['narf', 'poink'], array_keys($routes_array), 'Ensure the fitness was taken into account.');
       $this->assertNotNull($routes->get('narf'), 'The first matching route was found.');
       $this->assertNotNull($routes->get('poink'), 'The second matching route was found.');
       $this->assertNull($routes->get('eep'), 'Non-matching route was not found.');
@@ -469,8 +469,8 @@ public function testOutlinePathMatchDefaultsCollision3() {
       $routes = $provider->getRouteCollectionForRequest($request);
       $routes_array = $routes->all();
 
-      $this->assertEqual(count($routes), 2, 'The correct number of routes was found.');
-      $this->assertEqual(['poink', 'poink2'], array_keys($routes_array), 'Ensure the fitness and name were taken into account in the sort.');
+      $this->assertEquals(count($routes), 2, 'The correct number of routes was found.');
+      $this->assertEquals(['poink', 'poink2'], array_keys($routes_array), 'Ensure the fitness and name were taken into account in the sort.');
       $this->assertNotNull($routes->get('poink'), 'The first matching route was found.');
       $this->assertNotNull($routes->get('poink2'), 'The second matching route was found.');
       $this->assertNull($routes->get('eep'), 'Non-matching route was not found.');
@@ -505,10 +505,10 @@ public function testOutlinePathMatchZero() {
 
       // All of the matching paths have the correct pattern.
       foreach ($routes as $route) {
-        $this->assertEqual($route->compile()->getPatternOutline(), '/some/path/%', 'Found path has correct pattern');
+        $this->assertEquals($route->compile()->getPatternOutline(), '/some/path/%', 'Found path has correct pattern');
       }
 
-      $this->assertEqual(count($routes), 1, 'The correct number of routes was found.');
+      $this->assertEquals(count($routes), 1, 'The correct number of routes was found.');
     }
     catch (ResourceNotFoundException $e) {
       $this->fail('No matchout route found with 0 as argument value');
@@ -560,9 +560,9 @@ public function testRouteCaching() {
     $provider->getRouteCollectionForRequest($request);
 
     $cache = $this->cache->get('route:/path/add/one:');
-    $this->assertEqual('/path/add/one', $cache->data['path']);
-    $this->assertEqual([], $cache->data['query']);
-    $this->assertEqual(3, count($cache->data['routes']));
+    $this->assertEquals('/path/add/one', $cache->data['path']);
+    $this->assertEquals([], $cache->data['query']);
+    $this->assertEquals(3, count($cache->data['routes']));
 
     // A path with query parameters.
     $path = '/path/add/one?foo=bar';
@@ -570,9 +570,9 @@ public function testRouteCaching() {
     $provider->getRouteCollectionForRequest($request);
 
     $cache = $this->cache->get('route:/path/add/one:foo=bar');
-    $this->assertEqual('/path/add/one', $cache->data['path']);
-    $this->assertEqual(['foo' => 'bar'], $cache->data['query']);
-    $this->assertEqual(3, count($cache->data['routes']));
+    $this->assertEquals('/path/add/one', $cache->data['path']);
+    $this->assertEquals(['foo' => 'bar'], $cache->data['query']);
+    $this->assertEquals(3, count($cache->data['routes']));
 
     // A path with placeholders.
     $path = '/path/1/one';
@@ -580,9 +580,9 @@ public function testRouteCaching() {
     $provider->getRouteCollectionForRequest($request);
 
     $cache = $this->cache->get('route:/path/1/one:');
-    $this->assertEqual('/path/1/one', $cache->data['path']);
-    $this->assertEqual([], $cache->data['query']);
-    $this->assertEqual(2, count($cache->data['routes']));
+    $this->assertEquals('/path/1/one', $cache->data['path']);
+    $this->assertEquals([], $cache->data['query']);
+    $this->assertEquals(2, count($cache->data['routes']));
 
     // A path with a path alias.
     /** @var \Drupal\Core\Path\AliasStorageInterface $path_storage */
@@ -597,9 +597,9 @@ public function testRouteCaching() {
     $provider->getRouteCollectionForRequest($request);
 
     $cache = $this->cache->get('route:/path/add-one:');
-    $this->assertEqual('/path/add/one', $cache->data['path']);
-    $this->assertEqual([], $cache->data['query']);
-    $this->assertEqual(3, count($cache->data['routes']));
+    $this->assertEquals('/path/add/one', $cache->data['path']);
+    $this->assertEquals([], $cache->data['query']);
+    $this->assertEquals(3, count($cache->data['routes']));
   }
 
   /**
@@ -616,11 +616,11 @@ public function testRouteByName() {
     $dumper->dump();
 
     $route = $provider->getRouteByName('route_a');
-    $this->assertEqual($route->getPath(), '/path/one', 'The right route pattern was found.');
-    $this->assertEqual($route->getMethods(), ['GET'], 'The right route method was found.');
+    $this->assertEquals($route->getPath(), '/path/one', 'The right route pattern was found.');
+    $this->assertEquals($route->getMethods(), ['GET'], 'The right route method was found.');
     $route = $provider->getRouteByName('route_b');
-    $this->assertEqual($route->getPath(), '/path/one', 'The right route pattern was found.');
-    $this->assertEqual($route->getMethods(), ['PUT'], 'The right route method was found.');
+    $this->assertEquals($route->getPath(), '/path/one', 'The right route pattern was found.');
+    $this->assertEquals($route->getMethods(), ['PUT'], 'The right route method was found.');
 
     $exception_thrown = FALSE;
     try {
@@ -632,9 +632,9 @@ public function testRouteByName() {
     $this->assertTrue($exception_thrown, 'Random route was not found.');
 
     $routes = $provider->getRoutesByNames(['route_c', 'route_d', $this->randomMachineName()]);
-    $this->assertEqual(count($routes), 2, 'Only two valid routes found.');
-    $this->assertEqual($routes['route_c']->getPath(), '/path/two');
-    $this->assertEqual($routes['route_d']->getPath(), '/path/three');
+    $this->assertEquals(count($routes), 2, 'Only two valid routes found.');
+    $this->assertEquals($routes['route_c']->getPath(), '/path/two');
+    $this->assertEquals($routes['route_d']->getPath(), '/path/three');
   }
 
   /**
@@ -649,15 +649,15 @@ public function testGetRoutesByPatternWithLongPatterns() {
     // even though we have not dumped the routes yet.
     $shortest = '/test/1/test2';
     $result = $provider->getRoutesByPattern($shortest);
-    $this->assertEqual($result->count(), 0);
+    $this->assertEquals($result->count(), 0);
     $candidates = $provider->getCandidateOutlines(explode('/', trim($shortest, '/')));
-    $this->assertEqual(count($candidates), 7);
+    $this->assertEquals(count($candidates), 7);
     // A longer patten is not found and returns no candidates
     $path_to_test = '/test/1/test2/2/test3/3/4/5/6/test4';
     $result = $provider->getRoutesByPattern($path_to_test);
-    $this->assertEqual($result->count(), 0);
+    $this->assertEquals($result->count(), 0);
     $candidates = $provider->getCandidateOutlines(explode('/', trim($path_to_test, '/')));
-    $this->assertEqual(count($candidates), 0);
+    $this->assertEquals(count($candidates), 0);
 
     // Add a matching route and dump it.
     $dumper = new MatcherDumper($connection, $this->state, 'test_routes');
@@ -667,32 +667,32 @@ public function testGetRoutesByPatternWithLongPatterns() {
     $dumper->dump();
 
     $result = $provider->getRoutesByPattern($path_to_test);
-    $this->assertEqual($result->count(), 1);
+    $this->assertEquals($result->count(), 1);
     // We can't compare the values of the routes directly, nor use
     // spl_object_hash() because they are separate instances.
-    $this->assertEqual(serialize($result->get('long_pattern')), serialize($collection->get('long_pattern')), 'The right route was found.');
+    $this->assertEquals(serialize($result->get('long_pattern')), serialize($collection->get('long_pattern')), 'The right route was found.');
     // We now have a single candidate outline.
     $candidates = $provider->getCandidateOutlines(explode('/', trim($path_to_test, '/')));
-    $this->assertEqual(count($candidates), 1);
+    $this->assertEquals(count($candidates), 1);
     // Longer and shorter patterns are not found. Both are longer than 3, so
     // we should not have any candidates either. The fact that we do not
     // get any candidates for a longer path is a security feature.
     $longer = '/test/1/test2/2/test3/3/4/5/6/test4/trailing/more/parts';
     $result = $provider->getRoutesByPattern($longer);
-    $this->assertEqual($result->count(), 0);
+    $this->assertEquals($result->count(), 0);
     $candidates = $provider->getCandidateOutlines(explode('/', trim($longer, '/')));
-    $this->assertEqual(count($candidates), 1);
+    $this->assertEquals(count($candidates), 1);
     $shorter = '/test/1/test2/2/test3';
     $result = $provider->getRoutesByPattern($shorter);
-    $this->assertEqual($result->count(), 0);
+    $this->assertEquals($result->count(), 0);
     $candidates = $provider->getCandidateOutlines(explode('/', trim($shorter, '/')));
-    $this->assertEqual(count($candidates), 0);
+    $this->assertEquals(count($candidates), 0);
     // This pattern has only 3 parts, so we will get candidates, but no routes.
     // This result is unchanged by running the dumper.
     $result = $provider->getRoutesByPattern($shortest);
-    $this->assertEqual($result->count(), 0);
+    $this->assertEquals($result->count(), 0);
     $candidates = $provider->getCandidateOutlines(explode('/', trim($shortest, '/')));
-    $this->assertEqual(count($candidates), 7);
+    $this->assertEquals(count($candidates), 7);
   }
 
   /**
@@ -711,15 +711,15 @@ public function testGetRoutesPaged() {
 
     // Query all the routes.
     $routes = $provider->getRoutesPaged(0);
-    $this->assertEqual(array_keys($routes), array_keys($fixture_routes));
+    $this->assertEquals(array_keys($routes), array_keys($fixture_routes));
 
     // Query non routes.
     $routes = $provider->getRoutesPaged(0, 0);
-    $this->assertEqual(array_keys($routes), []);
+    $this->assertEquals(array_keys($routes), []);
 
     // Query a limited sets of routes.
     $routes = $provider->getRoutesPaged(1, 2);
-    $this->assertEqual(array_keys($routes), array_slice(array_keys($fixture_routes), 1, 2));
+    $this->assertEquals(array_keys($routes), array_slice(array_keys($fixture_routes), 1, 2));
   }
 
 }
