diff --git a/core/modules/hal/src/Normalizer/EntityReferenceItemNormalizer.php b/core/modules/hal/src/Normalizer/EntityReferenceItemNormalizer.php
index 66268db..1bffc67 100644
--- a/core/modules/hal/src/Normalizer/EntityReferenceItemNormalizer.php
+++ b/core/modules/hal/src/Normalizer/EntityReferenceItemNormalizer.php
@@ -57,6 +57,7 @@ public function __construct(LinkManagerInterface $link_manager, EntityResolverIn
    * @param \Drupal\Core\Field\FieldItemInterface $field_item
    * @param null $format
    * @param array $context
+   *
    * @return array|scalar
    */
   public function normalize($field_item, $format = NULL, array $context = array()) {
@@ -90,6 +91,7 @@ public function normalize($field_item, $format = NULL, array $context = array())
     $field_name = $field_item->getParent()->getName();
     $entity = $field_item->getEntity();
     $field_uri = $this->linkManager->getRelationUri($entity->getEntityTypeId(), $entity->bundle(), $field_name);
+
     return array(
       '_links' => array(
         $field_uri => array($link),
@@ -110,6 +112,7 @@ protected function constructValue($data, $context) {
     if ($id = $this->entityResolver->resolve($this, $data, $target_type)) {
       return array('target_id' => $id);
     }
+
     return NULL;
   }
 
@@ -122,8 +125,10 @@ public function getUuid($data) {
       if (is_array($uuid)) {
         $uuid = reset($uuid);
       }
+
       return $uuid;
     }
+
     return NULL;
   }
 
diff --git a/core/modules/hal/src/Normalizer/FieldItemNormalizer.php b/core/modules/hal/src/Normalizer/FieldItemNormalizer.php
index 0700502..878978b 100644
--- a/core/modules/hal/src/Normalizer/FieldItemNormalizer.php
+++ b/core/modules/hal/src/Normalizer/FieldItemNormalizer.php
@@ -7,7 +7,6 @@
 
 namespace Drupal\hal\Normalizer;
 
-use Drupal\Core\Field\FieldDefinitionInterface;
 use Drupal\Core\Field\FieldItemInterface;
 use Symfony\Component\Serializer\Exception\InvalidArgumentException;
 
@@ -27,8 +26,6 @@ class FieldItemNormalizer extends NormalizerBase {
    * {@inheritdoc}
    */
   public function normalize($field_item, $format = NULL, array $context = array()) {
-    /** @var  $field_item \Drupal\Core\Field\FieldItemInterface */
-
     $values = $field_item->toArray();
     if (isset($context['langcode'])) {
       $values['lang'] = $context['langcode'];
@@ -52,9 +49,10 @@ public function denormalize($data, $class, $format = NULL, array $context = arra
     if (!isset($context['target_instance'])) {
       throw new InvalidArgumentException('$context[\'target_instance\'] must be set to denormalize with the FieldItemNormalizer');
     }
+
     /** @var \Drupal\Core\Field\FieldItemInterface $field_item */
     $field_item = $context['target_instance'];
-    if ($field_item->getParent() == NULL) {
+    if ($field_item->getParent() === NULL) {
       throw new InvalidArgumentException('The field item passed in via $context[\'target_instance\'] must have a parent set.');
     }
 
@@ -62,8 +60,6 @@ public function denormalize($data, $class, $format = NULL, array $context = arra
     if (isset($data['lang'])) {
       $langcode = $data['lang'];
       unset($data['lang']);
-
-      /** @var \Drupal\Core\Field\FieldDefinitionInterface $field_definition */
       $field_definition = $field_item->getFieldDefinition();
       if ($field_definition->isTranslatable()) {
         $field_item = $this->createTranslatedInstance($field_item, $langcode);
diff --git a/core/modules/hal/src/Normalizer/FieldNormalizer.php b/core/modules/hal/src/Normalizer/FieldNormalizer.php
index 4b60340..a43b0e2 100644
--- a/core/modules/hal/src/Normalizer/FieldNormalizer.php
+++ b/core/modules/hal/src/Normalizer/FieldNormalizer.php
@@ -68,7 +68,7 @@ public function denormalize($data, $class, $format = NULL, array $context = arra
     }
     /** @var \Drupal\Core\Field\FieldItemListInterface $field */
     $field = $context['target_instance'];
-    if ($field->getParent() == NULL) {
+    if ($field->getParent() === NULL) {
       throw new InvalidArgumentException('The field passed in via $context[\'target_instance\'] must have a parent set.');
     }
 
diff --git a/core/modules/hal/src/Normalizer/NormalizerBase.php b/core/modules/hal/src/Normalizer/NormalizerBase.php
index e1918f3..1fdc9c1 100644
--- a/core/modules/hal/src/Normalizer/NormalizerBase.php
+++ b/core/modules/hal/src/Normalizer/NormalizerBase.php
@@ -7,7 +7,6 @@
 
 namespace Drupal\hal\Normalizer;
 
-use Drupal\serialization\EntityResolver\EntityResolverInterface;
 use Drupal\serialization\Normalizer\NormalizerBase as SerializationNormalizerBase;
 use Symfony\Component\Serializer\Normalizer\DenormalizerInterface;
 use Symfony\Component\Serializer\Normalizer\NormalizerInterface;
diff --git a/core/modules/hal/tests/CollectionNormalizerTest.php b/core/modules/hal/src/Tests/CollectionNormalizerTest.php
similarity index 100%
rename from core/modules/hal/tests/CollectionNormalizerTest.php
rename to core/modules/hal/src/Tests/CollectionNormalizerTest.php
diff --git a/core/modules/hal/src/Tests/NormalizerTestBase.php b/core/modules/hal/src/Tests/NormalizerTestBase.php
index b5c06b9..397dd17 100644
--- a/core/modules/hal/src/Tests/NormalizerTestBase.php
+++ b/core/modules/hal/src/Tests/NormalizerTestBase.php
@@ -14,8 +14,8 @@
 use Drupal\hal\Normalizer\FieldItemNormalizer;
 use Drupal\hal\Normalizer\FieldNormalizer;
 use Drupal\language\Entity\ConfigurableLanguage;
-use Drupal\rest\LinkManager\LinkManager;
 use Drupal\rest\LinkManager\CollectionLinkManager;
+use Drupal\rest\LinkManager\LinkManager;
 use Drupal\rest\LinkManager\RelationLinkManager;
 use Drupal\rest\LinkManager\TypeLinkManager;
 use Drupal\serialization\EntityResolver\ChainEntityResolver;
diff --git a/core/modules/rest/rest.services.yml b/core/modules/rest/rest.services.yml
index 388e513..58dde91 100644
--- a/core/modules/rest/rest.services.yml
+++ b/core/modules/rest/rest.services.yml
@@ -32,5 +32,3 @@ services:
   logger.channel.rest:
     parent: logger.channel_base
     arguments: ['rest']
-  rest.link_manager.collection:
-    class: Drupal\rest\LinkManager\CollectionLinkManager
diff --git a/core/modules/rest/src/Plugin/views/display/RestExport.php b/core/modules/rest/src/Plugin/views/display/RestExport.php
index 43eb4d6..ce6232d 100644
--- a/core/modules/rest/src/Plugin/views/display/RestExport.php
+++ b/core/modules/rest/src/Plugin/views/display/RestExport.php
@@ -261,6 +261,7 @@ public function collectRoutes(RouteCollection $collection) {
       // Add the new requirements to the route.
       $route->addRequirements($requirements);
     }
+
     return $result;
   }
 
diff --git a/core/modules/rest/src/Tests/Views/StyleSerializerTest.php b/core/modules/rest/src/Tests/Views/StyleSerializerTest.php
index 2641515..b1c92ca 100644
--- a/core/modules/rest/src/Tests/Views/StyleSerializerTest.php
+++ b/core/modules/rest/src/Tests/Views/StyleSerializerTest.php
@@ -8,13 +8,12 @@
 namespace Drupal\rest\Tests\Views;
 
 use Drupal\Component\Utility\String;
-use Drupal\serialization\Collection;
+use Drupal\Core\Url;
 use Drupal\views\ViewExecutable;
 use Drupal\views\Views;
 use Drupal\views\Tests\Plugin\PluginTestBase;
 use Drupal\views\Tests\ViewTestData;
-use Symfony\Component\HttpFoundation\Request;
-use Drupal\Component\Utility\Json;
+use Drupal\Component\Serialization\Json;
 
 /**
  * Tests the serializer style plugin.
@@ -121,6 +120,7 @@ public function testSerializerResponses() {
     $view = Views::getView('test_serializer_display_field');
     $view->initDisplay();
     $this->executeView($view);
+
     // application/json-type serialization.
     $actual_json = $this->drupalGetJSON('test/serialize/field');
     $this->assertResponse(200);
@@ -177,7 +177,7 @@ public function testSerializerResponses() {
     $this->assertTrue(isset($actual_json['_embedded']) && isset($actual_json['_links']), 'Has _links and _embedded keys');
 
     $this->assertEqual(count($actual_json['_embedded']['item']), 10);
-    $this->assertEqual($actual_json['_links']['self']['href'], url($view->getUrl(), array('absolute' => TRUE)));
+    $this->assertEqual($actual_json['_links']['self']['href'], Url::fromUri($view->getUrl(), array('absolute' => TRUE)));
     $this->assertEqual(array_keys($actual_json['_links']), array('self'));
   }
 
@@ -204,10 +204,10 @@ protected function testSerializerPageableCollectionHalJsonResponses() {
     $this->assertTrue(isset($actual_json['_embedded']) && isset($actual_json['_links']), 'Has _links and _embedded keys');
 
     $this->assertEqual(count($actual_json['_embedded']['item']), 1);
-    $this->assertEqual($actual_json['_links']['self']['href'], url($view->getUrl(), array('absolute' => TRUE)));
-    $this->assertEqual($actual_json['_links']['first']['href'], url($view->getUrl(), array('query' => array('page' => 0), 'absolute' => TRUE)));
-    $this->assertEqual($actual_json['_links']['next']['href'], url($view->getUrl(), array('query' => array('page' => 1), 'absolute' => TRUE)));
-    $this->assertEqual($actual_json['_links']['last']['href'], url($view->getUrl(), array('query' => array('page' => 9), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json['_links']['self']['href'], Url::fromUri($view->getUrl(), array('absolute' => TRUE)));
+    $this->assertEqual($actual_json['_links']['first']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 0), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json['_links']['next']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 1), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json['_links']['last']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 9), 'absolute' => TRUE)));
     $this->assertEqual(array_keys($actual_json['_links']), array(
       'self',
       'first',
@@ -220,11 +220,11 @@ protected function testSerializerPageableCollectionHalJsonResponses() {
     $this->assertTrue(isset($actual_json_page_1['_embedded']) && isset($actual_json_page_1['_links']), 'Has _links and _embedded keys');
 
     $this->assertEqual(count($actual_json_page_1['_embedded']['item']), 1);
-    $this->assertEqual($actual_json_page_1['_links']['self']['href'], url($view->getUrl(), array('query' => array('page' => 1), 'absolute' => TRUE)));
-    $this->assertEqual($actual_json_page_1['_links']['first']['href'], url($view->getUrl(), array('query' => array('page' => 0), 'absolute' => TRUE)));
-    $this->assertEqual($actual_json_page_1['_links']['prev']['href'], url($view->getUrl(), array('query' => array('page' => 0), 'absolute' => TRUE)));
-    $this->assertEqual($actual_json_page_1['_links']['next']['href'], url($view->getUrl(), array('query' => array('page' => 2), 'absolute' => TRUE)));
-    $this->assertEqual($actual_json_page_1['_links']['last']['href'], url($view->getUrl(), array('query' => array('page' => 9), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json_page_1['_links']['self']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 1), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json_page_1['_links']['first']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 0), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json_page_1['_links']['prev']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 0), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json_page_1['_links']['next']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 2), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json_page_1['_links']['last']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 9), 'absolute' => TRUE)));
     $this->assertEqual(array_keys($actual_json_page_1['_links']), array(
       'self',
       'first',
@@ -252,10 +252,10 @@ protected function testSerializerPageableCollectionHalJsonResponses() {
     $this->assertTrue(isset($actual_json_page_last['_embedded']) && isset($actual_json_page_last['_links']), 'Has _links and _embedded keys');
 
     $this->assertEqual(count($actual_json_page_last['_embedded']['item']), 1);
-    $this->assertEqual($actual_json_page_last['_links']['self']['href'], url($view->getUrl(), array('query' => array('page' => 9), 'absolute' => TRUE)));
-    $this->assertEqual($actual_json_page_last['_links']['first']['href'], url($view->getUrl(), array('query' => array('page' => 0), 'absolute' => TRUE)));
-    $this->assertEqual($actual_json_page_last['_links']['prev']['href'], url($view->getUrl(), array('query' => array('page' => 8), 'absolute' => TRUE)));
-    $this->assertEqual($actual_json_page_last['_links']['last']['href'], url($view->getUrl(), array('query' => array('page' => 9), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json_page_last['_links']['self']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 9), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json_page_last['_links']['first']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 0), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json_page_last['_links']['prev']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 8), 'absolute' => TRUE)));
+    $this->assertEqual($actual_json_page_last['_links']['last']['href'], Url::fromUri($view->getUrl(), array('query' => array('page' => 9), 'absolute' => TRUE)));
     $this->assertEqual(array_keys($actual_json_page_last['_links']), array(
       'self',
       'first',
@@ -387,7 +387,6 @@ public function testUIFieldAlias() {
     $this->assertIdentical($this->drupalGetJSON('test/serialize/field'), $expected);
   }
 
-
   /**
    * Tests the Serializer paths and responses for field-based views.
    */
@@ -571,6 +570,7 @@ public function testLivePreview() {
 
     // Get the serializer service.
     $serializer = $this->container->get('serializer');
+
     // Create the collection.
     $collection = $this->getCollectionFromView($view);
     $expected = String::checkPlain($serializer->serialize($collection, 'json'));
diff --git a/core/modules/serialization/tests/Drupal/serialization/Tests/CollectionTest.php b/core/modules/serialization/src/Tests/CollectionTest.php
similarity index 98%
rename from core/modules/serialization/tests/Drupal/serialization/Tests/CollectionTest.php
rename to core/modules/serialization/src/Tests/CollectionTest.php
index 7d8f0aa..53a7103 100644
--- a/core/modules/serialization/tests/Drupal/serialization/Tests/CollectionTest.php
+++ b/core/modules/serialization/src/Tests/CollectionTest.php
@@ -41,7 +41,7 @@ public static function getInfo() {
    * @covers ::setDescription
    */
   public function testConstructor() {
-    $collection_id = $this->randomName();
+    $collection_id = $this->randomMachineName();
     $collection = new Collection($collection_id);
     $this->assertSame($collection_id, $collection->getCollectionId(), 'Id has been set accordingly');
 
diff --git a/core/modules/toolbar/js/escapeAdmin.js b/core/modules/toolbar/js/escapeAdmin.js
index 0544a40..554d6a7 100644
--- a/core/modules/toolbar/js/escapeAdmin.js
+++ b/core/modules/toolbar/js/escapeAdmin.js
@@ -28,14 +28,11 @@
   Drupal.behaviors.escapeAdmin = {
     attach: function () {
       var $toolbarEscape = $('[data-toolbar-escape-admin]').once('escapeAdmin');
-      if ($toolbarEscape.length && pathInfo.currentPathIsAdmin) {
-        if (escapeAdminPath !== null) {
+      if ($toolbarEscape.length) {
+        if (pathInfo.currentPathIsAdmin && escapeAdminPath !== null) {
           $toolbarEscape.attr('href', escapeAdminPath);
+          $toolbarEscape.closest('.toolbar-tab').removeClass('hidden');
         }
-        else {
-          $toolbarEscape.text(Drupal.t('Home'));
-        }
-        $toolbarEscape.closest('.toolbar-tab').removeClass('hidden');
       }
     }
   };
