From ac65a88bed216502c5c7e1f35de6601516870297 Mon Sep 17 00:00:00 2001
From: catch <catch@35733.no-reply.drupal.org>
Date: Sat, 16 Nov 2019 23:09:26 +0000
Subject: [PATCH] Issue #3094292 by Berdir, plach, jibran, ravi.shankar: Remove
 usages of deprecated path alias services and clear "DeprecationListenerTrait"
 entries

---
 core/core.api.php                                    |  4 ++--
 core/core.services.yml                               |  4 ++--
 .../Drupal/Core/EventSubscriber/PathSubscriber.php   |  6 +++---
 core/lib/Drupal/Core/Path/AliasManager.php           |  6 +++---
 core/lib/Drupal/Core/Path/AliasRepository.php        |  6 +++---
 core/lib/Drupal/Core/Path/AliasWhitelist.php         |  6 +++---
 .../Drupal/Core/PathProcessor/PathProcessorAlias.php |  6 +++---
 .../tests/src/Kernel/ContentModerationStateTest.php  |  1 +
 .../locale/tests/src/Functional/LocalePathTest.php   |  4 ++--
 core/modules/path/src/PathAliasListBuilder.php       | 10 +++++-----
 .../src/Plugin/Field/FieldType/PathFieldItemList.php |  2 +-
 .../path/src/Plugin/migrate/source/UrlAliasBase.php  |  6 +++---
 .../path/tests/src/Functional/PathAliasTest.php      |  2 +-
 .../path/tests/src/Functional/PathLanguageTest.php   | 12 ++++++------
 core/modules/path/tests/src/Kernel/PathItemTest.php  |  2 +-
 core/modules/path_alias/src/Entity/PathAlias.php     |  4 ++--
 .../tests/src/Functional/UrlAlterFunctionalTest.php  |  2 +-
 .../path_alias/tests/src/Kernel/AliasTest.php        |  8 ++++----
 .../path_alias/tests/src/Kernel/PathHooksTest.php    |  6 +++---
 .../path_alias/tests/src/Unit/AliasManagerTest.php   |  4 ++--
 core/modules/system/src/Form/SiteInformationForm.php | 11 +++++------
 .../system/src/Plugin/Condition/RequestPath.php      |  8 ++++----
 .../system/src/Tests/Routing/MockAliasManager.php    |  2 +-
 .../views/src/Plugin/views/argument_default/Raw.php  |  9 ++++-----
 .../src/Unit/Plugin/argument_default/RawTest.php     |  5 +++--
 core/modules/views_ui/views_ui.module                |  2 +-
 .../EventSubscriber/WorkspaceRequestSubscriber.php   |  6 +++---
 core/modules/workspaces/src/WorkspaceManager.php     |  2 +-
 ...ceSupportedNewEntitiesConstraintValidatorTest.php |  1 +
 .../tests/src/Kernel/WorkspaceAccessTest.php         |  1 +
 .../tests/src/Kernel/WorkspaceCRUDTest.php           |  1 +
 .../tests/src/Kernel/WorkspaceIntegrationTest.php    |  1 +
 .../tests/src/Kernel/WorkspaceMergerTest.php         |  1 +
 .../src/Unit/WorkspaceRequestSubscriberTest.php      |  4 ++--
 core/modules/workspaces/workspaces.services.yml      |  2 +-
 .../modules/demo_umami_content/src/InstallHelper.php |  8 ++++----
 .../Drupal/KernelTests/Config/DefaultConfigTest.php  |  2 +-
 .../Core/Plugin/Condition/RequestPathTest.php        |  2 +-
 .../KernelTests/Core/Routing/RouteProviderTest.php   |  4 ++--
 .../Compiler/ProxyServicesPassTest.php               |  3 ++-
 .../Tests/Core/PathProcessor/PathProcessorTest.php   | 10 +++++-----
 .../Drupal/Tests/Core/Routing/UrlGeneratorTest.php   |  8 ++++----
 core/tests/Drupal/Tests/Core/UrlTest.php             |  6 +++---
 .../Tests/Listeners/DeprecationListenerTrait.php     |  9 ---------
 44 files changed, 103 insertions(+), 106 deletions(-)

diff --git a/core/core.api.php b/core/core.api.php
index 9bd8ae99b7b5..0e9e0835d9c3 100644
--- a/core/core.api.php
+++ b/core/core.api.php
@@ -761,9 +761,9 @@
  *
  * A typical service definition in a *.services.yml file looks like this:
  * @code
- * path.alias_manager:
+ * path_alias.manager:
  *   class: Drupal\path_alias\AliasManager
- *   arguments: ['@path.crud', '@path_alias.whitelist', '@language_manager']
+ *   arguments: ['@path_alias.repository', '@path_alias.whitelist', '@language_manager']
  * @endcode
  * Some services use other services as factories; a typical service definition
  * is:
diff --git a/core/core.services.yml b/core/core.services.yml
index 4dd909dbf63e..61f6eef8ef0c 100644
--- a/core/core.services.yml
+++ b/core/core.services.yml
@@ -1206,7 +1206,7 @@ services:
       - { name: event_subscriber }
   path_subscriber:
     class: Drupal\Core\EventSubscriber\PathSubscriber
-    arguments: ['@path.alias_manager', '@path.current']
+    arguments: ['@path_alias.manager', '@path.current']
     deprecated: 'The "%service_id%" service is deprecated. Use "path_alias.subscriber" instead. See https://drupal.org/node/3092086'
   route_access_response_subscriber:
     class: Drupal\Core\EventSubscriber\RouteAccessResponseSubscriber
@@ -1340,7 +1340,7 @@ services:
       - { name: route_processor_outbound, priority: 200 }
   path_processor_alias:
     class: Drupal\Core\PathProcessor\PathProcessorAlias
-    arguments: ['@path.alias_manager']
+    arguments: ['@path_alias.manager']
     deprecated: 'The "%service_id%" service is deprecated. Use "path_alias.path_processor" instead. See https://drupal.org/node/3092086'
   route_processor_csrf:
     class: Drupal\Core\Access\RouteProcessorCsrf
diff --git a/core/lib/Drupal/Core/EventSubscriber/PathSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/PathSubscriber.php
index f25bc49b4ac5..8af509847605 100644
--- a/core/lib/Drupal/Core/EventSubscriber/PathSubscriber.php
+++ b/core/lib/Drupal/Core/EventSubscriber/PathSubscriber.php
@@ -12,10 +12,10 @@
 /**
  * Provides a path subscriber that converts path aliases.
  *
- *   @deprecated in drupal:8.8.0 and is removed from drupal:9.0.0.
- *   Use \Drupal\path_alias\EventSubscriber\PathAliasSubscriber.
+ * @deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Use
+ *   \Drupal\path_alias\EventSubscriber\PathAliasSubscriber instead.
  *
- *   @see https://www.drupal.org/node/3092086
+ * @see https://www.drupal.org/node/3092086
  */
 class PathSubscriber implements EventSubscriberInterface {
 
diff --git a/core/lib/Drupal/Core/Path/AliasManager.php b/core/lib/Drupal/Core/Path/AliasManager.php
index 4c95089369f2..5673f6627be5 100644
--- a/core/lib/Drupal/Core/Path/AliasManager.php
+++ b/core/lib/Drupal/Core/Path/AliasManager.php
@@ -12,10 +12,10 @@
 /**
  * The default alias manager implementation.
  *
- *   @deprecated in drupal:8.8.0 and is removed from drupal:9.0.0.
- *   Use \Drupal\path_alias\AliasManager.
+ * @deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Use
+ *   \Drupal\path_alias\AliasManager instead.
  *
- *   @see https://www.drupal.org/node/3092086
+ * @see https://www.drupal.org/node/3092086
  */
 class AliasManager implements AliasManagerInterface, CacheDecoratorInterface {
 
diff --git a/core/lib/Drupal/Core/Path/AliasRepository.php b/core/lib/Drupal/Core/Path/AliasRepository.php
index 7c28161fdfc0..d6f3717b7652 100644
--- a/core/lib/Drupal/Core/Path/AliasRepository.php
+++ b/core/lib/Drupal/Core/Path/AliasRepository.php
@@ -10,10 +10,10 @@
 /**
  * Provides the default path alias lookup operations.
  *
- *   @deprecated in drupal:8.8.0 and is removed from drupal:9.0.0.
- *   Use \Drupal\path_alias\AliasRepository.
+ * @deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Use
+ *   \Drupal\path_alias\AliasRepository instead.
  *
- *   @see https://www.drupal.org/node/3092086
+ * @see https://www.drupal.org/node/3092086
  */
 class AliasRepository implements AliasRepositoryInterface {
 
diff --git a/core/lib/Drupal/Core/Path/AliasWhitelist.php b/core/lib/Drupal/Core/Path/AliasWhitelist.php
index ff6c193f67de..79f2ba6dc624 100644
--- a/core/lib/Drupal/Core/Path/AliasWhitelist.php
+++ b/core/lib/Drupal/Core/Path/AliasWhitelist.php
@@ -11,10 +11,10 @@
 /**
  * Extends CacheCollector to build the path alias whitelist over time.
  *
- *   @deprecated in drupal:8.8.0 and is removed from drupal:9.0.0.
- *   Use \Drupal\path_alias\AliasWhitelist.
+ * @deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Use
+ *   \Drupal\path_alias\AliasWhitelist instead.
  *
- *   @see https://www.drupal.org/node/3092086
+ * @see https://www.drupal.org/node/3092086
  */
 class AliasWhitelist extends CacheCollector implements AliasWhitelistInterface {
 
diff --git a/core/lib/Drupal/Core/PathProcessor/PathProcessorAlias.php b/core/lib/Drupal/Core/PathProcessor/PathProcessorAlias.php
index de7f29c6a70f..bae2028f3232 100644
--- a/core/lib/Drupal/Core/PathProcessor/PathProcessorAlias.php
+++ b/core/lib/Drupal/Core/PathProcessor/PathProcessorAlias.php
@@ -9,10 +9,10 @@
 /**
  * Processes the inbound path using path alias lookups.
  *
- *   @deprecated in drupal:8.8.0 and is removed from drupal:9.0.0.
- *   Use \Drupal\path_alias\PathProcessor\AliasPathProcessor.
+ * @deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Use
+ *   \Drupal\path_alias\PathProcessor\AliasPathProcessor.
  *
- *   @see https://www.drupal.org/node/3092086
+ * @see https://www.drupal.org/node/3092086
  */
 class PathProcessorAlias implements InboundPathProcessorInterface, OutboundPathProcessorInterface {
 
diff --git a/core/modules/content_moderation/tests/src/Kernel/ContentModerationStateTest.php b/core/modules/content_moderation/tests/src/Kernel/ContentModerationStateTest.php
index eadfa65f528e..3e17d0beda58 100644
--- a/core/modules/content_moderation/tests/src/Kernel/ContentModerationStateTest.php
+++ b/core/modules/content_moderation/tests/src/Kernel/ContentModerationStateTest.php
@@ -47,6 +47,7 @@ class ContentModerationStateTest extends KernelTestBase {
     'content_translation',
     'text',
     'workflows',
+    'path_alias',
   ];
 
   /**
diff --git a/core/modules/locale/tests/src/Functional/LocalePathTest.php b/core/modules/locale/tests/src/Functional/LocalePathTest.php
index 9b1584e44682..036b95747011 100644
--- a/core/modules/locale/tests/src/Functional/LocalePathTest.php
+++ b/core/modules/locale/tests/src/Functional/LocalePathTest.php
@@ -106,10 +106,10 @@ public function testPathLanguageConfiguration() {
 
     // Check priority of language for alias by source path.
     $path_alias = $this->createPathAlias('/node/' . $node->id(), '/' . $custom_path, LanguageInterface::LANGCODE_NOT_SPECIFIED);
-    $lookup_path = $this->container->get('path.alias_manager')->getAliasByPath('/node/' . $node->id(), 'en');
+    $lookup_path = $this->container->get('path_alias.manager')->getAliasByPath('/node/' . $node->id(), 'en');
     $this->assertEqual('/' . $english_path, $lookup_path, 'English language alias has priority.');
     // Same check for language 'xx'.
-    $lookup_path = $this->container->get('path.alias_manager')->getAliasByPath('/node/' . $node->id(), $prefix);
+    $lookup_path = $this->container->get('path_alias.manager')->getAliasByPath('/node/' . $node->id(), $prefix);
     $this->assertEqual('/' . $custom_language_path, $lookup_path, 'Custom language alias has priority.');
     $path_alias->delete();
 
diff --git a/core/modules/path/src/PathAliasListBuilder.php b/core/modules/path/src/PathAliasListBuilder.php
index 0d6dc539e7e9..4c6ca4622c30 100644
--- a/core/modules/path/src/PathAliasListBuilder.php
+++ b/core/modules/path/src/PathAliasListBuilder.php
@@ -9,7 +9,7 @@
 use Drupal\Core\Entity\EntityTypeInterface;
 use Drupal\Core\Form\FormBuilderInterface;
 use Drupal\Core\Language\LanguageManagerInterface;
-use Drupal\Core\Path\AliasManagerInterface;
+use Drupal\path_alias\AliasManagerInterface;
 use Drupal\Core\Url;
 use Drupal\path\Form\PathFilterForm;
 use Symfony\Component\DependencyInjection\ContainerInterface;
@@ -18,7 +18,7 @@
 /**
  * Defines a class to build a listing of path_alias entities.
  *
- * @see \Drupal\Core\Path\Entity\PathAlias
+ * @see \Drupal\path_alias\Entity\PathAlias
  */
 class PathAliasListBuilder extends EntityListBuilder {
 
@@ -46,7 +46,7 @@ class PathAliasListBuilder extends EntityListBuilder {
   /**
    * The path alias manager.
    *
-   * @var \Drupal\Core\Path\AliasManagerInterface
+   * @var \Drupal\path_alias\AliasManagerInterface
    */
   protected $aliasManager;
 
@@ -63,7 +63,7 @@ class PathAliasListBuilder extends EntityListBuilder {
    *   The form builder.
    * @param \Drupal\Core\Language\LanguageManagerInterface $language_manager
    *   The language manager.
-   * @param \Drupal\Core\Path\AliasManagerInterface $alias_manager
+   * @param \Drupal\path_alias\AliasManagerInterface $alias_manager
    *   The path alias manager.
    */
   public function __construct(EntityTypeInterface $entity_type, EntityStorageInterface $storage, Request $current_request, FormBuilderInterface $form_builder, LanguageManagerInterface $language_manager, AliasManagerInterface $alias_manager) {
@@ -85,7 +85,7 @@ public static function createInstance(ContainerInterface $container, EntityTypeI
       $container->get('request_stack')->getCurrentRequest(),
       $container->get('form_builder'),
       $container->get('language_manager'),
-      $container->get('path.alias_manager')
+      $container->get('path_alias.manager')
     );
   }
 
diff --git a/core/modules/path/src/Plugin/Field/FieldType/PathFieldItemList.php b/core/modules/path/src/Plugin/Field/FieldType/PathFieldItemList.php
index a791d7afeb0a..0836df17abca 100644
--- a/core/modules/path/src/Plugin/Field/FieldType/PathFieldItemList.php
+++ b/core/modules/path/src/Plugin/Field/FieldType/PathFieldItemList.php
@@ -26,7 +26,7 @@ protected function computeValue() {
 
     $entity = $this->getEntity();
     if (!$entity->isNew()) {
-      /** @var \Drupal\Core\Path\AliasRepositoryInterface $path_alias_repository */
+      /** @var \Drupal\path_alias\AliasRepositoryInterface $path_alias_repository */
       $path_alias_repository = \Drupal::service('path_alias.repository');
 
       if ($path_alias = $path_alias_repository->lookupBySystemPath('/' . $entity->toUrl()->getInternalPath(), $this->getLangcode())) {
diff --git a/core/modules/path/src/Plugin/migrate/source/UrlAliasBase.php b/core/modules/path/src/Plugin/migrate/source/UrlAliasBase.php
index b2e7e0d758a2..79e6400355fb 100644
--- a/core/modules/path/src/Plugin/migrate/source/UrlAliasBase.php
+++ b/core/modules/path/src/Plugin/migrate/source/UrlAliasBase.php
@@ -14,9 +14,9 @@ abstract class UrlAliasBase extends DrupalSqlBase {
    */
   public function query() {
     // The order of the migration is significant since
-    // \Drupal\Core\Path\AliasRepository::lookupPathAlias() orders by pid before
-    // returning a result. Postgres does not automatically order by primary key
-    // therefore we need to add a specific order by.
+    // \Drupal\path_alias\AliasRepository::lookupPathAlias() orders by pid
+    // before returning a result. Postgres does not automatically order by
+    // primary key therefore we need to add a specific order by.
     return $this->select('url_alias', 'ua')->fields('ua')->orderBy('pid');
   }
 
diff --git a/core/modules/path/tests/src/Functional/PathAliasTest.php b/core/modules/path/tests/src/Functional/PathAliasTest.php
index 54c200873dcd..0ef6b99304bc 100644
--- a/core/modules/path/tests/src/Functional/PathAliasTest.php
+++ b/core/modules/path/tests/src/Functional/PathAliasTest.php
@@ -120,7 +120,7 @@ public function testAdminAlias() {
     $this->assertText($node1->label(), 'Changed alias works.');
     $this->assertResponse(200);
 
-    $this->container->get('path.alias_manager')->cacheClear();
+    $this->container->get('path_alias.manager')->cacheClear();
     // Confirm that previous alias no longer works.
     $this->drupalGet($previous);
     $this->assertNoText($node1->label(), 'Previous alias no longer works.');
diff --git a/core/modules/path/tests/src/Functional/PathLanguageTest.php b/core/modules/path/tests/src/Functional/PathLanguageTest.php
index 7f2167108cbb..a5982e15d8b4 100644
--- a/core/modules/path/tests/src/Functional/PathLanguageTest.php
+++ b/core/modules/path/tests/src/Functional/PathLanguageTest.php
@@ -101,7 +101,7 @@ public function testAliasTranslation() {
     $this->drupalPostForm(NULL, $edit, t('Save (this translation)'));
 
     // Clear the path lookup cache.
-    $this->container->get('path.alias_manager')->cacheClear();
+    $this->container->get('path_alias.manager')->cacheClear();
 
     // Languages are cached on many levels, and we need to clear those caches.
     $this->container->get('language_manager')->reset();
@@ -172,18 +172,18 @@ public function testAliasTranslation() {
 
     // The alias manager has an internal path lookup cache. Check to see that
     // it has the appropriate contents at this point.
-    $this->container->get('path.alias_manager')->cacheClear();
-    $french_node_path = $this->container->get('path.alias_manager')->getPathByAlias('/' . $french_alias, 'fr');
+    $this->container->get('path_alias.manager')->cacheClear();
+    $french_node_path = $this->container->get('path_alias.manager')->getPathByAlias('/' . $french_alias, 'fr');
     $this->assertEqual($french_node_path, '/node/' . $english_node_french_translation->id(), 'Normal path works.');
     // Second call should return the same path.
-    $french_node_path = $this->container->get('path.alias_manager')->getPathByAlias('/' . $french_alias, 'fr');
+    $french_node_path = $this->container->get('path_alias.manager')->getPathByAlias('/' . $french_alias, 'fr');
     $this->assertEqual($french_node_path, '/node/' . $english_node_french_translation->id(), 'Normal path is the same.');
 
     // Confirm that the alias works.
-    $french_node_alias = $this->container->get('path.alias_manager')->getAliasByPath('/node/' . $english_node_french_translation->id(), 'fr');
+    $french_node_alias = $this->container->get('path_alias.manager')->getAliasByPath('/node/' . $english_node_french_translation->id(), 'fr');
     $this->assertEqual($french_node_alias, '/' . $french_alias, 'Alias works.');
     // Second call should return the same alias.
-    $french_node_alias = $this->container->get('path.alias_manager')->getAliasByPath('/node/' . $english_node_french_translation->id(), 'fr');
+    $french_node_alias = $this->container->get('path_alias.manager')->getAliasByPath('/node/' . $english_node_french_translation->id(), 'fr');
     $this->assertEqual($french_node_alias, '/' . $french_alias, 'Alias is the same.');
 
     // Confirm that the alias is removed if the translation is deleted.
diff --git a/core/modules/path/tests/src/Kernel/PathItemTest.php b/core/modules/path/tests/src/Kernel/PathItemTest.php
index 3398116d454c..240b6cf54a7b 100644
--- a/core/modules/path/tests/src/Kernel/PathItemTest.php
+++ b/core/modules/path/tests/src/Kernel/PathItemTest.php
@@ -44,7 +44,7 @@ protected function setUp() {
    * Test creating, loading, updating and deleting aliases through PathItem.
    */
   public function testPathItem() {
-    /** @var \Drupal\Core\Path\AliasRepositoryInterface $alias_repository */
+    /** @var \Drupal\path_alias\AliasRepositoryInterface $alias_repository */
     $alias_repository = \Drupal::service('path_alias.repository');
 
     $node_storage = \Drupal::entityTypeManager()->getStorage('node');
diff --git a/core/modules/path_alias/src/Entity/PathAlias.php b/core/modules/path_alias/src/Entity/PathAlias.php
index 209d160d5460..aabbaaff1e1c 100644
--- a/core/modules/path_alias/src/Entity/PathAlias.php
+++ b/core/modules/path_alias/src/Entity/PathAlias.php
@@ -106,7 +106,7 @@ public function preSave(EntityStorageInterface $storage) {
   public function postSave(EntityStorageInterface $storage, $update = TRUE) {
     parent::postSave($storage, $update);
 
-    $alias_manager = \Drupal::service('path.alias_manager');
+    $alias_manager = \Drupal::service('path_alias.manager');
     $alias_manager->cacheClear($this->getPath());
     if ($update) {
       $alias_manager->cacheClear($this->original->getPath());
@@ -119,7 +119,7 @@ public function postSave(EntityStorageInterface $storage, $update = TRUE) {
   public static function postDelete(EntityStorageInterface $storage, array $entities) {
     parent::postDelete($storage, $entities);
 
-    $alias_manager = \Drupal::service('path.alias_manager');
+    $alias_manager = \Drupal::service('path_alias.manager');
     foreach ($entities as $entity) {
       $alias_manager->cacheClear($entity->getPath());
     }
diff --git a/core/modules/path_alias/tests/src/Functional/UrlAlterFunctionalTest.php b/core/modules/path_alias/tests/src/Functional/UrlAlterFunctionalTest.php
index 800c8e86c980..42f789db28e9 100644
--- a/core/modules/path_alias/tests/src/Functional/UrlAlterFunctionalTest.php
+++ b/core/modules/path_alias/tests/src/Functional/UrlAlterFunctionalTest.php
@@ -119,7 +119,7 @@ protected function assertUrlOutboundAlter($original, $final) {
    */
   protected function assertUrlInboundAlter($original, $final) {
     // Test inbound altering.
-    $result = $this->container->get('path.alias_manager')->getPathByAlias($original);
+    $result = $this->container->get('path_alias.manager')->getPathByAlias($original);
     return $this->assertIdentical($result, $final, new FormattableMarkup('Altered inbound URL %original, expected %final, and got %result.', ['%original' => $original, '%final' => $final, '%result' => $result]));
   }
 
diff --git a/core/modules/path_alias/tests/src/Kernel/AliasTest.php b/core/modules/path_alias/tests/src/Kernel/AliasTest.php
index b9c3cc358e01..083a4cc2c85e 100644
--- a/core/modules/path_alias/tests/src/Kernel/AliasTest.php
+++ b/core/modules/path_alias/tests/src/Kernel/AliasTest.php
@@ -12,7 +12,7 @@
 /**
  * Tests path alias CRUD and lookup functionality.
  *
- * @coversDefaultClass \Drupal\Core\Path\AliasRepository
+ * @coversDefaultClass \Drupal\path_alias\AliasRepository
  *
  * @group path_alias
  */
@@ -61,12 +61,12 @@ public function testLookupByAlias() {
   }
 
   /**
-   * @covers \Drupal\Core\Path\AliasManager::getPathByAlias
-   * @covers \Drupal\Core\Path\AliasManager::getAliasByPath
+   * @covers \Drupal\path_alias\AliasManager::getPathByAlias
+   * @covers \Drupal\path_alias\AliasManager::getAliasByPath
    */
   public function testLookupPath() {
     // Create AliasManager and Path object.
-    $aliasManager = $this->container->get('path.alias_manager');
+    $aliasManager = $this->container->get('path_alias.manager');
 
     // Test the situation where the source is the same for multiple aliases.
     // Start with a language-neutral alias, which we will override.
diff --git a/core/modules/path_alias/tests/src/Kernel/PathHooksTest.php b/core/modules/path_alias/tests/src/Kernel/PathHooksTest.php
index 2a7b86743174..80e2683a4095 100644
--- a/core/modules/path_alias/tests/src/Kernel/PathHooksTest.php
+++ b/core/modules/path_alias/tests/src/Kernel/PathHooksTest.php
@@ -45,7 +45,7 @@ public function testPathHooks() {
     $alias_manager = $this->prophesize(AliasManagerInterface::class);
     $alias_manager->cacheClear(Argument::any())->shouldBeCalledTimes(1);
     $alias_manager->cacheClear($path_alias->getPath())->shouldBeCalledTimes(1);
-    \Drupal::getContainer()->set('path.alias_manager', $alias_manager->reveal());
+    \Drupal::getContainer()->set('path_alias.manager', $alias_manager->reveal());
     $path_alias->save();
 
     $new_source = '/' . $this->randomMachineName();
@@ -56,7 +56,7 @@ public function testPathHooks() {
     $alias_manager->cacheClear(Argument::any())->shouldBeCalledTimes(2);
     $alias_manager->cacheClear($path_alias->getPath())->shouldBeCalledTimes(1);
     $alias_manager->cacheClear($new_source)->shouldBeCalledTimes(1);
-    \Drupal::getContainer()->set('path.alias_manager', $alias_manager->reveal());
+    \Drupal::getContainer()->set('path_alias.manager', $alias_manager->reveal());
     $path_alias->setPath($new_source);
     $path_alias->save();
 
@@ -64,7 +64,7 @@ public function testPathHooks() {
     $alias_manager = $this->prophesize(AliasManagerInterface::class);
     $alias_manager->cacheClear(Argument::any())->shouldBeCalledTimes(1);
     $alias_manager->cacheClear($new_source)->shouldBeCalledTimes(1);
-    \Drupal::getContainer()->set('path.alias_manager', $alias_manager->reveal());
+    \Drupal::getContainer()->set('path_alias.manager', $alias_manager->reveal());
     $path_alias->delete();
   }
 
diff --git a/core/modules/path_alias/tests/src/Unit/AliasManagerTest.php b/core/modules/path_alias/tests/src/Unit/AliasManagerTest.php
index c0b767480eb2..e260fb6834a3 100644
--- a/core/modules/path_alias/tests/src/Unit/AliasManagerTest.php
+++ b/core/modules/path_alias/tests/src/Unit/AliasManagerTest.php
@@ -4,7 +4,7 @@
 
 use Drupal\Core\Language\Language;
 use Drupal\Core\Language\LanguageInterface;
-use Drupal\Core\Path\AliasRepositoryInterface;
+use Drupal\path_alias\AliasRepositoryInterface;
 use Drupal\path_alias\AliasManager;
 use Drupal\Tests\UnitTestCase;
 
@@ -31,7 +31,7 @@ class AliasManagerTest extends UnitTestCase {
   /**
    * Alias repository.
    *
-   * @var \Drupal\Core\Path\AliasRepositoryInterface|\PHPUnit\Framework\MockObject\MockObject
+   * @var \Drupal\path_alias\AliasRepositoryInterface|\PHPUnit\Framework\MockObject\MockObject
    */
   protected $aliasRepository;
 
diff --git a/core/modules/system/src/Form/SiteInformationForm.php b/core/modules/system/src/Form/SiteInformationForm.php
index 4e4e1571fd54..a74545fa90ce 100644
--- a/core/modules/system/src/Form/SiteInformationForm.php
+++ b/core/modules/system/src/Form/SiteInformationForm.php
@@ -3,11 +3,11 @@
 namespace Drupal\system\Form;
 
 use Drupal\Core\Config\ConfigFactoryInterface;
-use Drupal\Core\Form\FormStateInterface;
-use Drupal\Core\Path\AliasManagerInterface;
 use Drupal\Core\Form\ConfigFormBase;
+use Drupal\Core\Form\FormStateInterface;
 use Drupal\Core\Path\PathValidatorInterface;
 use Drupal\Core\Routing\RequestContext;
+use Drupal\path_alias\AliasManagerInterface;
 use Symfony\Component\DependencyInjection\ContainerInterface;
 
 /**
@@ -20,7 +20,7 @@ class SiteInformationForm extends ConfigFormBase {
   /**
    * The path alias manager.
    *
-   * @var \Drupal\Core\Path\AliasManagerInterface
+   * @var \Drupal\path_alias\AliasManagerInterface
    */
   protected $aliasManager;
 
@@ -43,7 +43,7 @@ class SiteInformationForm extends ConfigFormBase {
    *
    * @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
    *   The factory for configuration objects.
-   * @param \Drupal\Core\Path\AliasManagerInterface $alias_manager
+   * @param \Drupal\path_alias\AliasManagerInterface $alias_manager
    *   The path alias manager.
    * @param \Drupal\Core\Path\PathValidatorInterface $path_validator
    *   The path validator.
@@ -52,7 +52,6 @@ class SiteInformationForm extends ConfigFormBase {
    */
   public function __construct(ConfigFactoryInterface $config_factory, AliasManagerInterface $alias_manager, PathValidatorInterface $path_validator, RequestContext $request_context) {
     parent::__construct($config_factory);
-
     $this->aliasManager = $alias_manager;
     $this->pathValidator = $path_validator;
     $this->requestContext = $request_context;
@@ -64,7 +63,7 @@ public function __construct(ConfigFactoryInterface $config_factory, AliasManager
   public static function create(ContainerInterface $container) {
     return new static(
       $container->get('config.factory'),
-      $container->get('path.alias_manager'),
+      $container->get('path_alias.manager'),
       $container->get('path.validator'),
       $container->get('router.request_context')
     );
diff --git a/core/modules/system/src/Plugin/Condition/RequestPath.php b/core/modules/system/src/Plugin/Condition/RequestPath.php
index 1f73624774be..6b5801cf1a36 100644
--- a/core/modules/system/src/Plugin/Condition/RequestPath.php
+++ b/core/modules/system/src/Plugin/Condition/RequestPath.php
@@ -4,10 +4,10 @@
 
 use Drupal\Core\Condition\ConditionPluginBase;
 use Drupal\Core\Form\FormStateInterface;
-use Drupal\Core\Path\AliasManagerInterface;
 use Drupal\Core\Path\CurrentPathStack;
 use Drupal\Core\Path\PathMatcherInterface;
 use Drupal\Core\Plugin\ContainerFactoryPluginInterface;
+use Drupal\path_alias\AliasManagerInterface;
 use Symfony\Component\DependencyInjection\ContainerInterface;
 use Symfony\Component\HttpFoundation\RequestStack;
 
@@ -24,7 +24,7 @@ class RequestPath extends ConditionPluginBase implements ContainerFactoryPluginI
   /**
    * An alias manager to find the alias for the current system path.
    *
-   * @var \Drupal\Core\Path\AliasManagerInterface
+   * @var \Drupal\path_alias\AliasManagerInterface
    */
   protected $aliasManager;
 
@@ -52,7 +52,7 @@ class RequestPath extends ConditionPluginBase implements ContainerFactoryPluginI
   /**
    * Constructs a RequestPath condition plugin.
    *
-   * @param \Drupal\Core\Path\AliasManagerInterface $alias_manager
+   * @param \Drupal\path_alias\AliasManagerInterface $alias_manager
    *   An alias manager to find the alias for the current system path.
    * @param \Drupal\Core\Path\PathMatcherInterface $path_matcher
    *   The path matcher service.
@@ -80,7 +80,7 @@ public function __construct(AliasManagerInterface $alias_manager, PathMatcherInt
    */
   public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
     return new static(
-      $container->get('path.alias_manager'),
+      $container->get('path_alias.manager'),
       $container->get('path.matcher'),
       $container->get('request_stack'),
       $container->get('path.current'),
diff --git a/core/modules/system/src/Tests/Routing/MockAliasManager.php b/core/modules/system/src/Tests/Routing/MockAliasManager.php
index 09f36366fc67..dcbfbe7162bc 100644
--- a/core/modules/system/src/Tests/Routing/MockAliasManager.php
+++ b/core/modules/system/src/Tests/Routing/MockAliasManager.php
@@ -2,7 +2,7 @@
 
 namespace Drupal\system\Tests\Routing;
 
-use Drupal\Core\Path\AliasManagerInterface;
+use Drupal\path_alias\AliasManagerInterface;
 
 /**
  * An easily configurable mock alias manager.
diff --git a/core/modules/views/src/Plugin/views/argument_default/Raw.php b/core/modules/views/src/Plugin/views/argument_default/Raw.php
index 2491bd83c0da..f44215b7fafe 100644
--- a/core/modules/views/src/Plugin/views/argument_default/Raw.php
+++ b/core/modules/views/src/Plugin/views/argument_default/Raw.php
@@ -5,8 +5,8 @@
 use Drupal\Core\Cache\Cache;
 use Drupal\Core\Cache\CacheableDependencyInterface;
 use Drupal\Core\Form\FormStateInterface;
-use Drupal\Core\Path\AliasManagerInterface;
 use Drupal\Core\Path\CurrentPathStack;
+use Drupal\path_alias\AliasManagerInterface;
 use Symfony\Component\DependencyInjection\ContainerInterface;
 
 /**
@@ -24,7 +24,7 @@ class Raw extends ArgumentDefaultPluginBase implements CacheableDependencyInterf
   /**
    * The alias manager.
    *
-   * @var \Drupal\Core\Path\AliasManagerInterface
+   * @var \Drupal\path_alias\AliasManagerInterface
    */
   protected $aliasManager;
 
@@ -44,14 +44,13 @@ class Raw extends ArgumentDefaultPluginBase implements CacheableDependencyInterf
    *   The plugin_id for the plugin instance.
    * @param mixed $plugin_definition
    *   The plugin implementation definition.
-   * @param \Drupal\Core\Path\AliasManagerInterface $alias_manager
+   * @param \Drupal\path_alias\AliasManagerInterface $alias_manager
    *   The alias manager.
    * @param \Drupal\Core\Path\CurrentPathStack $current_path
    *   The current path.
    */
   public function __construct(array $configuration, $plugin_id, $plugin_definition, AliasManagerInterface $alias_manager, CurrentPathStack $current_path) {
     parent::__construct($configuration, $plugin_id, $plugin_definition);
-
     $this->aliasManager = $alias_manager;
     $this->currentPath = $current_path;
   }
@@ -64,7 +63,7 @@ public static function create(ContainerInterface $container, array $configuratio
       $configuration,
       $plugin_id,
       $plugin_definition,
-      $container->get('path.alias_manager'),
+      $container->get('path_alias.manager'),
       $container->get('path.current')
     );
   }
diff --git a/core/modules/views/tests/src/Unit/Plugin/argument_default/RawTest.php b/core/modules/views/tests/src/Unit/Plugin/argument_default/RawTest.php
index cc8f2c78df7e..c3c7dd140d52 100644
--- a/core/modules/views/tests/src/Unit/Plugin/argument_default/RawTest.php
+++ b/core/modules/views/tests/src/Unit/Plugin/argument_default/RawTest.php
@@ -3,6 +3,7 @@
 namespace Drupal\Tests\views\Unit\Plugin\argument_default;
 
 use Drupal\Core\Path\CurrentPathStack;
+use Drupal\path_alias\AliasManagerInterface;
 use Drupal\Tests\UnitTestCase;
 use Drupal\views\Plugin\views\argument_default\Raw;
 use Symfony\Component\HttpFoundation\Request;
@@ -33,7 +34,7 @@ public function testGetArgument() {
     $view->expects($this->any())
       ->method('getRequest')
       ->will($this->returnValue($request));
-    $alias_manager = $this->createMock('Drupal\Core\Path\AliasManagerInterface');
+    $alias_manager = $this->createMock(AliasManagerInterface::class);
     $alias_manager->expects($this->never())
       ->method('getAliasByPath');
 
@@ -71,7 +72,7 @@ public function testGetArgument() {
     $this->assertEquals(NULL, $raw->getArgument());
 
     // Setup an alias manager with a path alias.
-    $alias_manager = $this->createMock('Drupal\Core\Path\AliasManagerInterface');
+    $alias_manager = $this->createMock(AliasManagerInterface::class);
     $alias_manager->expects($this->any())
       ->method('getAliasByPath')
       ->with($this->equalTo('/test/example'))
diff --git a/core/modules/views_ui/views_ui.module b/core/modules/views_ui/views_ui.module
index dea9361b4885..da5c0bb7e7be 100644
--- a/core/modules/views_ui/views_ui.module
+++ b/core/modules/views_ui/views_ui.module
@@ -323,7 +323,7 @@ function views_ui_views_analyze(ViewExecutable $view) {
       continue;
     }
     if ($display->hasPath() && $path = $display->getOption('path')) {
-      $normal_path = \Drupal::service('path.alias_manager')->getPathByAlias($path);
+      $normal_path = \Drupal::service('path_alias.manager')->getPathByAlias($path);
       if ($path != $normal_path) {
         $ret[] = Analyzer::formatMessage(t('You have configured display %display with a path which is an path alias as well. This might lead to unwanted effects so better use an internal path.', ['%display' => $display->display['display_title']]), 'warning');
       }
diff --git a/core/modules/workspaces/src/EventSubscriber/WorkspaceRequestSubscriber.php b/core/modules/workspaces/src/EventSubscriber/WorkspaceRequestSubscriber.php
index e44d36b02ad4..fdab25ecb7eb 100644
--- a/core/modules/workspaces/src/EventSubscriber/WorkspaceRequestSubscriber.php
+++ b/core/modules/workspaces/src/EventSubscriber/WorkspaceRequestSubscriber.php
@@ -2,7 +2,7 @@
 
 namespace Drupal\workspaces\EventSubscriber;
 
-use Drupal\Core\Path\AliasManagerInterface;
+use Drupal\path_alias\AliasManagerInterface;
 use Drupal\Core\Path\CurrentPathStack;
 use Drupal\Core\Routing\CacheableRouteProviderInterface;
 use Drupal\Core\Routing\RouteProviderInterface;
@@ -20,7 +20,7 @@ class WorkspaceRequestSubscriber implements EventSubscriberInterface {
   /**
    * The alias manager that caches alias lookups based on the request.
    *
-   * @var \Drupal\Core\Path\AliasManagerInterface
+   * @var \Drupal\path_alias\AliasManagerInterface
    */
   protected $aliasManager;
 
@@ -48,7 +48,7 @@ class WorkspaceRequestSubscriber implements EventSubscriberInterface {
   /**
    * Constructs a new WorkspaceRequestSubscriber instance.
    *
-   * @param \Drupal\Core\Path\AliasManagerInterface $alias_manager
+   * @param \Drupal\path_alias\AliasManagerInterface $alias_manager
    *   The alias manager.
    * @param \Drupal\Core\Path\CurrentPathStack $current_path
    *   The current path.
diff --git a/core/modules/workspaces/src/WorkspaceManager.php b/core/modules/workspaces/src/WorkspaceManager.php
index 499c5cd786a4..541ca88564a4 100644
--- a/core/modules/workspaces/src/WorkspaceManager.php
+++ b/core/modules/workspaces/src/WorkspaceManager.php
@@ -265,7 +265,7 @@ protected function doSwitchWorkspace($workspace) {
 
     // Clear the static cache for path aliases. We can't inject the path alias
     // manager service because it would create a circular dependency.
-    \Drupal::service('path.alias_manager')->cacheClear();
+    \Drupal::service('path_alias.manager')->cacheClear();
   }
 
   /**
diff --git a/core/modules/workspaces/tests/src/Kernel/EntityReferenceSupportedNewEntitiesConstraintValidatorTest.php b/core/modules/workspaces/tests/src/Kernel/EntityReferenceSupportedNewEntitiesConstraintValidatorTest.php
index 5cef79df930d..ae5ceb8ea5d2 100644
--- a/core/modules/workspaces/tests/src/Kernel/EntityReferenceSupportedNewEntitiesConstraintValidatorTest.php
+++ b/core/modules/workspaces/tests/src/Kernel/EntityReferenceSupportedNewEntitiesConstraintValidatorTest.php
@@ -25,6 +25,7 @@ class EntityReferenceSupportedNewEntitiesConstraintValidatorTest extends KernelT
     'user',
     'workspaces',
     'entity_test',
+    'path_alias',
   ];
 
   /**
diff --git a/core/modules/workspaces/tests/src/Kernel/WorkspaceAccessTest.php b/core/modules/workspaces/tests/src/Kernel/WorkspaceAccessTest.php
index e59b350731aa..bfd23ef8e41a 100644
--- a/core/modules/workspaces/tests/src/Kernel/WorkspaceAccessTest.php
+++ b/core/modules/workspaces/tests/src/Kernel/WorkspaceAccessTest.php
@@ -25,6 +25,7 @@ class WorkspaceAccessTest extends KernelTestBase {
     'system',
     'workspaces',
     'workspace_access_test',
+    'path_alias',
   ];
 
   /**
diff --git a/core/modules/workspaces/tests/src/Kernel/WorkspaceCRUDTest.php b/core/modules/workspaces/tests/src/Kernel/WorkspaceCRUDTest.php
index 80c655bd42d8..36b837feacfd 100644
--- a/core/modules/workspaces/tests/src/Kernel/WorkspaceCRUDTest.php
+++ b/core/modules/workspaces/tests/src/Kernel/WorkspaceCRUDTest.php
@@ -53,6 +53,7 @@ class WorkspaceCRUDTest extends KernelTestBase {
     'filter',
     'node',
     'text',
+    'path_alias',
   ];
 
   /**
diff --git a/core/modules/workspaces/tests/src/Kernel/WorkspaceIntegrationTest.php b/core/modules/workspaces/tests/src/Kernel/WorkspaceIntegrationTest.php
index b2f0d42d2a17..6466a803583a 100644
--- a/core/modules/workspaces/tests/src/Kernel/WorkspaceIntegrationTest.php
+++ b/core/modules/workspaces/tests/src/Kernel/WorkspaceIntegrationTest.php
@@ -67,6 +67,7 @@ class WorkspaceIntegrationTest extends KernelTestBase {
     'views',
     'language',
     'content_translation',
+    'path_alias',
   ];
 
   /**
diff --git a/core/modules/workspaces/tests/src/Kernel/WorkspaceMergerTest.php b/core/modules/workspaces/tests/src/Kernel/WorkspaceMergerTest.php
index 2a3342f9964a..59cc86ddb6df 100644
--- a/core/modules/workspaces/tests/src/Kernel/WorkspaceMergerTest.php
+++ b/core/modules/workspaces/tests/src/Kernel/WorkspaceMergerTest.php
@@ -45,6 +45,7 @@ class WorkspaceMergerTest extends KernelTestBase {
     'text',
     'user',
     'system',
+    'path_alias',
   ];
 
   /**
diff --git a/core/modules/workspaces/tests/src/Unit/WorkspaceRequestSubscriberTest.php b/core/modules/workspaces/tests/src/Unit/WorkspaceRequestSubscriberTest.php
index e5f109832d0c..3aba7fb2af55 100644
--- a/core/modules/workspaces/tests/src/Unit/WorkspaceRequestSubscriberTest.php
+++ b/core/modules/workspaces/tests/src/Unit/WorkspaceRequestSubscriberTest.php
@@ -2,7 +2,7 @@
 
 namespace Drupal\Tests\workspaces\Unit;
 
-use Drupal\Core\Path\AliasManagerInterface;
+use Drupal\path_alias\AliasManagerInterface;
 use Drupal\Core\Path\CurrentPathStack;
 use Drupal\Core\Routing\CacheableRouteProviderInterface;
 use Drupal\Core\Routing\RouteProviderInterface;
@@ -20,7 +20,7 @@
 class WorkspaceRequestSubscriberTest extends UnitTestCase {
 
   /**
-   * @var \Drupal\Core\Path\AliasManagerInterface
+   * @var \Drupal\path_alias\AliasManagerInterface
    */
   protected $aliasManager;
 
diff --git a/core/modules/workspaces/workspaces.services.yml b/core/modules/workspaces/workspaces.services.yml
index ee7b573becac..1db8c49ebffa 100644
--- a/core/modules/workspaces/workspaces.services.yml
+++ b/core/modules/workspaces/workspaces.services.yml
@@ -40,7 +40,7 @@ services:
       - { name: 'event_subscriber' }
   workspaces.workspace_subscriber:
     class: Drupal\workspaces\EventSubscriber\WorkspaceRequestSubscriber
-    arguments: ['@path.alias_manager', '@path.current', '@router.route_provider', '@workspaces.manager']
+    arguments: ['@path_alias.manager', '@path.current', '@router.route_provider', '@workspaces.manager']
     tags:
       - { name: event_subscriber }
 
diff --git a/core/profiles/demo_umami/modules/demo_umami_content/src/InstallHelper.php b/core/profiles/demo_umami/modules/demo_umami_content/src/InstallHelper.php
index acd87a0ba9a3..6835cc3bd025 100644
--- a/core/profiles/demo_umami/modules/demo_umami_content/src/InstallHelper.php
+++ b/core/profiles/demo_umami/modules/demo_umami_content/src/InstallHelper.php
@@ -8,7 +8,7 @@
 use Drupal\Core\Extension\ModuleHandlerInterface;
 use Drupal\Core\File\Exception\FileException;
 use Drupal\Core\File\FileSystemInterface;
-use Drupal\Core\Path\AliasManagerInterface;
+use Drupal\path_alias\AliasManagerInterface;
 use Drupal\Core\State\StateInterface;
 use Symfony\Component\DependencyInjection\ContainerInterface;
 
@@ -23,7 +23,7 @@ class InstallHelper implements ContainerInjectionInterface {
   /**
    * The path alias manager.
    *
-   * @var \Drupal\Core\Path\AliasManagerInterface
+   * @var \Drupal\path_alias\AliasManagerInterface
    */
   protected $aliasManager;
 
@@ -99,7 +99,7 @@ class InstallHelper implements ContainerInjectionInterface {
   /**
    * Constructs a new InstallHelper object.
    *
-   * @param \Drupal\Core\Path\AliasManagerInterface $aliasManager
+   * @param \Drupal\path_alias\AliasManagerInterface $aliasManager
    *   The path alias manager.
    * @param \Drupal\Core\Entity\EntityTypeManagerInterface $entityTypeManager
    *   Entity type manager.
@@ -127,7 +127,7 @@ public function __construct(AliasManagerInterface $aliasManager, EntityTypeManag
    */
   public static function create(ContainerInterface $container) {
     return new static(
-      $container->get('path.alias_manager'),
+      $container->get('path_alias.manager'),
       $container->get('entity_type.manager'),
       $container->get('module_handler'),
       $container->get('state'),
diff --git a/core/tests/Drupal/KernelTests/Config/DefaultConfigTest.php b/core/tests/Drupal/KernelTests/Config/DefaultConfigTest.php
index 91bec84427c0..17006fc3e388 100644
--- a/core/tests/Drupal/KernelTests/Config/DefaultConfigTest.php
+++ b/core/tests/Drupal/KernelTests/Config/DefaultConfigTest.php
@@ -28,7 +28,7 @@ class DefaultConfigTest extends KernelTestBase {
   /**
    * {@inheritdoc}
    */
-  public static $modules = ['system', 'user'];
+  public static $modules = ['system', 'user', 'path_alias'];
 
   /**
    * The following config entries are changed on module install.
diff --git a/core/tests/Drupal/KernelTests/Core/Plugin/Condition/RequestPathTest.php b/core/tests/Drupal/KernelTests/Core/Plugin/Condition/RequestPathTest.php
index f9b56859d44f..12569a6ca72d 100644
--- a/core/tests/Drupal/KernelTests/Core/Plugin/Condition/RequestPathTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Plugin/Condition/RequestPathTest.php
@@ -63,7 +63,7 @@ protected function setUp() {
 
     // Set a mock alias manager in the container.
     $this->aliasManager = new MockAliasManager();
-    $this->container->set('path.alias_manager', $this->aliasManager);
+    $this->container->set('path_alias.manager', $this->aliasManager);
 
     // Set the test request stack in the container.
     $this->requestStack = new RequestStack();
diff --git a/core/tests/Drupal/KernelTests/Core/Routing/RouteProviderTest.php b/core/tests/Drupal/KernelTests/Core/Routing/RouteProviderTest.php
index 7ab002d9c06a..6daa3964c8d7 100644
--- a/core/tests/Drupal/KernelTests/Core/Routing/RouteProviderTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Routing/RouteProviderTest.php
@@ -576,8 +576,8 @@ public function testRouteCaching() {
 
     // A path with a path alias.
     $this->createPathAlias('/path/add/one', '/path/add-one');
-    /** @var \Drupal\Core\Path\AliasManagerInterface $alias_manager */
-    $alias_manager = \Drupal::service('path.alias_manager');
+    /** @var \Drupal\path_alias\AliasManagerInterface $alias_manager */
+    $alias_manager = \Drupal::service('path_alias.manager');
     $alias_manager->cacheClear();
 
     $path = '/path/add-one';
diff --git a/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/ProxyServicesPassTest.php b/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/ProxyServicesPassTest.php
index 63b94ff4638d..d9cb77aea9c4 100644
--- a/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/ProxyServicesPassTest.php
+++ b/core/tests/Drupal/Tests/Core/DependencyInjection/Compiler/ProxyServicesPassTest.php
@@ -4,6 +4,7 @@
 
 use Drupal\Core\DependencyInjection\Compiler\ProxyServicesPass;
 use Drupal\Core\DependencyInjection\ContainerBuilder;
+use Drupal\Core\Path\CurrentPathStack;
 use Drupal\Tests\UnitTestCase;
 use Symfony\Component\DependencyInjection\Exception\InvalidArgumentException;
 
@@ -67,7 +68,7 @@ public function testContainerWithLazyServices() {
    */
   public function testContainerWithLazyServicesWithoutProxyClass() {
     $container = new ContainerBuilder();
-    $container->register('alias_whitelist', 'Drupal\Core\Path\AliasWhitelist')
+    $container->register('path.current', CurrentPathStack::class)
       ->setLazy(TRUE);
 
     $this->expectException(InvalidArgumentException::class);
diff --git a/core/tests/Drupal/Tests/Core/PathProcessor/PathProcessorTest.php b/core/tests/Drupal/Tests/Core/PathProcessor/PathProcessorTest.php
index ce401b125576..0233f71e1df9 100644
--- a/core/tests/Drupal/Tests/Core/PathProcessor/PathProcessorTest.php
+++ b/core/tests/Drupal/Tests/Core/PathProcessor/PathProcessorTest.php
@@ -4,15 +4,15 @@
 
 use Drupal\Core\Language\Language;
 use Drupal\Core\Language\LanguageInterface;
-use Drupal\Core\PathProcessor\PathProcessorAlias;
 use Drupal\Core\PathProcessor\PathProcessorDecode;
 use Drupal\Core\PathProcessor\PathProcessorFront;
 use Drupal\Core\PathProcessor\PathProcessorManager;
 use Drupal\language\HttpKernel\PathProcessorLanguage;
 use Drupal\language\Plugin\LanguageNegotiation\LanguageNegotiationUrl;
-use Symfony\Component\HttpFoundation\Request;
-
+use Drupal\path_alias\AliasManager;
+use Drupal\path_alias\PathProcessor\AliasPathProcessor;
 use Drupal\Tests\UnitTestCase;
+use Symfony\Component\HttpFoundation\Request;
 
 /**
  * Tests processing of the inbound path.
@@ -87,7 +87,7 @@ protected function setUp() {
   public function testProcessInbound() {
 
     // Create an alias manager stub.
-    $alias_manager = $this->getMockBuilder('Drupal\Core\Path\AliasManager')
+    $alias_manager = $this->getMockBuilder(AliasManager::class)
       ->disableOriginalConstructor()
       ->getMock();
 
@@ -148,7 +148,7 @@ public function testProcessInbound() {
       ->getMock();
 
     // Create the processors.
-    $alias_processor = new PathProcessorAlias($alias_manager);
+    $alias_processor = new AliasPathProcessor($alias_manager);
     $decode_processor = new PathProcessorDecode();
     $front_processor = new PathProcessorFront($config_factory_stub);
     $language_processor = new PathProcessorLanguage($config_factory_stub, $this->languageManager, $negotiator, $current_user, $config_subscriber);
diff --git a/core/tests/Drupal/Tests/Core/Routing/UrlGeneratorTest.php b/core/tests/Drupal/Tests/Core/Routing/UrlGeneratorTest.php
index c01aafac0d74..35ebc81c8181 100644
--- a/core/tests/Drupal/Tests/Core/Routing/UrlGeneratorTest.php
+++ b/core/tests/Drupal/Tests/Core/Routing/UrlGeneratorTest.php
@@ -5,12 +5,12 @@
 use Drupal\Core\Cache\Cache;
 use Drupal\Core\DependencyInjection\ContainerBuilder;
 use Drupal\Core\PathProcessor\OutboundPathProcessorInterface;
-use Drupal\Core\PathProcessor\PathProcessorAlias;
 use Drupal\Core\PathProcessor\PathProcessorManager;
 use Drupal\Core\Render\BubbleableMetadata;
 use Drupal\Core\Routing\RequestContext;
 use Drupal\Core\Routing\RouteProviderInterface;
 use Drupal\Core\Routing\UrlGenerator;
+use Drupal\path_alias\PathProcessor\AliasPathProcessor;
 use Drupal\Tests\UnitTestCase;
 use Prophecy\Argument;
 use Symfony\Component\HttpFoundation\Request;
@@ -43,7 +43,7 @@ class UrlGeneratorTest extends UnitTestCase {
   /**
    * The alias manager.
    *
-   * @var \Drupal\Core\Path\AliasManager|\PHPUnit\Framework\MockObject\MockObject
+   * @var \Drupal\path_alias\AliasManager|\PHPUnit\Framework\MockObject\MockObject
    */
   protected $aliasManager;
 
@@ -143,7 +143,7 @@ protected function setUp() {
       ->will($this->returnValueMap($routes_names_return_map));
 
     // Create an alias manager stub.
-    $alias_manager = $this->getMockBuilder('Drupal\Core\Path\AliasManager')
+    $alias_manager = $this->getMockBuilder('Drupal\path_alias\AliasManager')
       ->disableOriginalConstructor()
       ->getMock();
 
@@ -160,7 +160,7 @@ protected function setUp() {
     $this->context = new RequestContext();
     $this->context->fromRequestStack($this->requestStack);
 
-    $processor = new PathProcessorAlias($this->aliasManager);
+    $processor = new AliasPathProcessor($this->aliasManager);
     $processor_manager = new PathProcessorManager();
     $processor_manager->addOutbound($processor, 1000);
     $this->processorManager = $processor_manager;
diff --git a/core/tests/Drupal/Tests/Core/UrlTest.php b/core/tests/Drupal/Tests/Core/UrlTest.php
index 4094a48d5732..5843bae302a7 100644
--- a/core/tests/Drupal/Tests/Core/UrlTest.php
+++ b/core/tests/Drupal/Tests/Core/UrlTest.php
@@ -42,7 +42,7 @@ class UrlTest extends UnitTestCase {
   /**
    * The path alias manager.
    *
-   * @var \Drupal\Core\Path\AliasManagerInterface|\PHPUnit\Framework\MockObject\MockObject
+   * @var \Drupal\path_alias\AliasManagerInterface|\PHPUnit\Framework\MockObject\MockObject
    */
   protected $pathAliasManager;
 
@@ -101,7 +101,7 @@ protected function setUp() {
       ->method('generateFromRoute')
       ->will($this->returnValueMap($generate_from_route_map));
 
-    $this->pathAliasManager = $this->createMock('Drupal\Core\Path\AliasManagerInterface');
+    $this->pathAliasManager = $this->createMock('Drupal\path_alias\AliasManagerInterface');
     $this->pathAliasManager->expects($this->any())
       ->method('getPathByAlias')
       ->will($this->returnValueMap($alias_map));
@@ -112,7 +112,7 @@ protected function setUp() {
     $this->container = new ContainerBuilder();
     $this->container->set('router.no_access_checks', $this->router);
     $this->container->set('url_generator', $this->urlGenerator);
-    $this->container->set('path.alias_manager', $this->pathAliasManager);
+    $this->container->set('path_alias.manager', $this->pathAliasManager);
     $this->container->set('path.validator', $this->pathValidator);
     \Drupal::setContainer($this->container);
   }
diff --git a/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php b/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php
index 9d3d49ed51c7..88d6387aabd5 100644
--- a/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php
+++ b/core/tests/Drupal/Tests/Listeners/DeprecationListenerTrait.php
@@ -190,15 +190,6 @@ public static function getSkippedDeprecations() {
       // The following deprecation is listed for Twig 2 compatibility when unit
       // testing using \Symfony\Component\ErrorHandler\DebugClassLoader.
       'The "Twig\Environment::getTemplateClass()" method is considered internal. It may change without further notice. You should not extend it from "Drupal\Core\Template\TwigEnvironment".',
-      // These deprecations are triggered when instantiating path alias
-      // services. The new versions live in the "path_alias" module.
-      // @todo Remove in https://www.drupal.org/node/3092090.
-      'The "path.alias_manager" service is deprecated. Use "path_alias.manager" instead. See https://drupal.org/node/3092086',
-      'The \Drupal\Core\EventSubscriber\PathSubscriber class is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Instead, use \Drupal\path_alias\EventSubscriber\PathAliasSubscriber. See https://drupal.org/node/3092086',
-      'The \Drupal\Core\PathProcessor\PathProcessorAlias class is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Instead, use \Drupal\path_alias\PathProcessor\AliasPathProcessor. See https://drupal.org/node/3092086',
-      'The \Drupal\Core\Path\AliasManager class is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Instead, use \Drupal\path_alias\AliasManager. See https://drupal.org/node/3092086',
-      'The \Drupal\Core\Path\AliasRepository class is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Instead, use \Drupal\path_alias\AliasRepository. See https://drupal.org/node/3092086',
-      'The \Drupal\Core\Path\AliasWhitelist class is deprecated in drupal:8.8.0 and is removed from drupal:9.0.0. Instead, use \Drupal\path_alias\AliasWhitelist. See https://drupal.org/node/3092086',
       '"Symfony\Component\DomCrawler\Crawler::text()" will normalize whitespaces by default in Symfony 5.0, set the second "$normalizeWhitespace" argument to false to retrieve the non-normalized version of the text.',
     ];
   }
-- 
GitLab