diff --git a/core/modules/system/tests/modules/url_alter_test/lib/Drupal/url_alter_test/Controller/URLAlterTestController.php b/core/modules/system/tests/modules/url_alter_test/lib/Drupal/url_alter_test/Controller/URLAlterTestController.php
new file mode 100644
index 0000000..da06222
--- /dev/null
+++ b/core/modules/system/tests/modules/url_alter_test/lib/Drupal/url_alter_test/Controller/URLAlterTestController.php
@@ -0,0 +1,26 @@
+<?php
+/**
+ * @file
+ * Contains \Drupal\url_alter_test\Controller\URLAlterTestController.
+ */
+
+namespace Drupal\url_alter_test\Controller;
+
+use Symfony\Component\HttpFoundation\Response;
+
+/**
+ * Controller routines for url_alter_test routes.
+ */
+class URLAlterTestController {
+
+  /**
+   * Prints Current and Request Path.
+   *
+   * @return \Symfony\Component\HttpFoundation\Response
+   *   A response object.
+   */
+  public function foo() {
+    return new Response('current_path=' . current_path() . ' request_path=' . request_path());
+  }
+
+}
diff --git a/core/modules/system/tests/modules/url_alter_test/url_alter_test.module b/core/modules/system/tests/modules/url_alter_test/url_alter_test.module
index a7567a3..b3d9bbc 100644
--- a/core/modules/system/tests/modules/url_alter_test/url_alter_test.module
+++ b/core/modules/system/tests/modules/url_alter_test/url_alter_test.module
@@ -1,27 +1 @@
 <?php
-
-/**
- * @file
- * Module to help test altering the inbound and outbound path.
- */
-
-/**
- * Implements hook_menu().
- */
-function url_alter_test_menu() {
-  $items['url-alter-test/foo'] = array(
-    'title' => 'Foo',
-    'page callback' => 'url_alter_test_foo',
-    'access arguments' => array('access content'),
-    'type' => MENU_CALLBACK,
-  );
-  return $items;
-}
-
-/**
- * Menu callback.
- */
-function url_alter_test_foo() {
-  print 'current_path=' . current_path() . ' request_path=' . request_path();
-  exit;
-}
diff --git a/core/modules/system/tests/modules/url_alter_test/url_alter_test.routing.yml b/core/modules/system/tests/modules/url_alter_test/url_alter_test.routing.yml
new file mode 100644
index 0000000..da07ab8
--- /dev/null
+++ b/core/modules/system/tests/modules/url_alter_test/url_alter_test.routing.yml
@@ -0,0 +1,6 @@
+url_alter_test_foo:
+  pattern: 'url-alter-test/foo'
+  defaults:
+    _content: '\Drupal\url_alter_test\Controller\URLAlterTestController::foo'
+  requirements:
+    _permission: 'access content'
