diff --git a/core/includes/update.inc b/core/includes/update.inc
index 2c020db6b2fb7b8dc3272f5bd75717d321a3b7d0..213d15d2fef9ef225ad866651a9d0cb5a1cd3b17 100644
--- a/core/includes/update.inc
+++ b/core/includes/update.inc
@@ -707,7 +707,7 @@ function update_language_list($flags = LanguageInterface::STATE_CONFIGURABLE) {
   // Initialize master language list.
   if (!isset($languages)) {
     // Initialize local language list cache.
-   $languages = array();
+    $languages = array();
 
     // Fill in master language list based on current configuration.
     $default = \Drupal::languageManager()->getDefaultLanguage();
diff --git a/core/lib/Drupal/Component/Utility/SortArray.php b/core/lib/Drupal/Component/Utility/SortArray.php
index 044a21492fcbaf88eadb55905454f95bc33beeef..2ef6223f73d21ea9c6ee7ff3365f9990dbaae068 100644
--- a/core/lib/Drupal/Component/Utility/SortArray.php
+++ b/core/lib/Drupal/Component/Utility/SortArray.php
@@ -81,9 +81,9 @@ public static function sortByTitleElement($a, $b) {
    * @return int
    *   The comparison result for uasort().
    */
-   public static function sortByTitleProperty($a, $b) {
-     return static::sortByKeyString($a, $b, '#title');
-   }
+  public static function sortByTitleProperty($a, $b) {
+    return static::sortByKeyString($a, $b, '#title');
+  }
 
   /**
    * Sorts a string array item by an arbitrary key.
diff --git a/core/lib/Drupal/Core/Config/Entity/Query/QueryFactory.php b/core/lib/Drupal/Core/Config/Entity/Query/QueryFactory.php
index 80a41c4f0362fca2552e799f40ffbe6b0daaddd7..0327e902b385d07aa4b912ab309b88b2b912aeeb 100644
--- a/core/lib/Drupal/Core/Config/Entity/Query/QueryFactory.php
+++ b/core/lib/Drupal/Core/Config/Entity/Query/QueryFactory.php
@@ -66,8 +66,8 @@ public function get(EntityTypeInterface $entity_type, $conjunction) {
   /**
    * {@inheritdoc}
    */
-   public function getAggregate(EntityTypeInterface $entity_type, $conjunction) {
-      throw new QueryException('Aggregation over configuration entities is not supported');
+  public function getAggregate(EntityTypeInterface $entity_type, $conjunction) {
+    throw new QueryException('Aggregation over configuration entities is not supported');
   }
 
   /**
diff --git a/core/lib/Drupal/Core/Database/Driver/pgsql/Install/Tasks.php b/core/lib/Drupal/Core/Database/Driver/pgsql/Install/Tasks.php
index 95ff52716fea56ed3f19f36ade9dfca5e1f2b295..7e78b1405d3ed677c813989c1952bcae15014a94 100644
--- a/core/lib/Drupal/Core/Database/Driver/pgsql/Install/Tasks.php
+++ b/core/lib/Drupal/Core/Database/Driver/pgsql/Install/Tasks.php
@@ -65,7 +65,7 @@ protected function connect() {
       $this->pass('Drupal can CONNECT to the database ok.');
     }
     catch (\Exception $e) {
-    // Attempt to create the database if it is not found.
+      // Attempt to create the database if it is not found.
       if ($e->getCode() == Connection::DATABASE_NOT_FOUND) {
         // Remove the database string from connection info.
         $connection_info = Database::getConnectionInfo();
diff --git a/core/lib/Drupal/Core/Database/StatementInterface.php b/core/lib/Drupal/Core/Database/StatementInterface.php
index 5bc9e48ef79fd36af4501dbeaab2dbcd3d90e6dc..971d031e032ba847fc7be9bccd2940d2d6cec4e7 100644
--- a/core/lib/Drupal/Core/Database/StatementInterface.php
+++ b/core/lib/Drupal/Core/Database/StatementInterface.php
@@ -90,7 +90,7 @@ public function rowCount();
    *   If $mode is PDO::FETCH_CLASS, the optional arguments to pass to the
    *   constructor.
    */
-   public function setFetchMode($mode, $a1 = NULL, $a2 = array());
+  public function setFetchMode($mode, $a1 = NULL, $a2 = array());
 
   /**
    * Fetches the next row from a result set.
@@ -109,7 +109,7 @@ public function setFetchMode($mode, $a1 = NULL, $a2 = array());
    * @return
    *   A result, formatted according to $mode.
    */
-   public function fetch($mode = NULL, $cursor_orientation = NULL, $cursor_offset = NULL);
+  public function fetch($mode = NULL, $cursor_orientation = NULL, $cursor_offset = NULL);
 
   /**
    * Returns a single field from the next record of a result set.
@@ -128,7 +128,7 @@ public function fetchField($index = 0);
    * The object will be of the class specified by StatementInterface::setFetchMode()
    * or stdClass if not specified.
    */
-   public function fetchObject();
+  public function fetchObject();
 
   /**
    * Fetches the next row and returns it as an associative array.
@@ -155,7 +155,7 @@ public function fetchAssoc();
    * @return
    *   An array of results.
    */
-   function fetchAll($mode = NULL, $column_index = NULL, $constructor_arguments = NULL);
+  function fetchAll($mode = NULL, $column_index = NULL, $constructor_arguments = NULL);
 
   /**
    * Returns an entire single column of a result set as an indexed array.
diff --git a/core/lib/Drupal/Core/DependencyInjection/Container.php b/core/lib/Drupal/Core/DependencyInjection/Container.php
index 157f576ed4567530b9d65b12a986acef559e3039..4a491225b0cc2813bfc9f0d193377a7bcdc12460 100644
--- a/core/lib/Drupal/Core/DependencyInjection/Container.php
+++ b/core/lib/Drupal/Core/DependencyInjection/Container.php
@@ -14,7 +14,7 @@ class Container extends DrupalContainer {
    * {@inheritdoc}
    */
   public function set($id, $service, $scope = ContainerInterface::SCOPE_CONTAINER) {
-     parent::set($id, $service, $scope);
+    parent::set($id, $service, $scope);
 
     // Ensure that the _serviceId property is set on synthetic services as well.
     if (isset($this->services[$id]) && is_object($this->services[$id]) && !isset($this->services[$id]->_serviceId)) {
diff --git a/core/lib/Drupal/Core/Entity/Plugin/Validation/Constraint/ReferenceAccessConstraintValidator.php b/core/lib/Drupal/Core/Entity/Plugin/Validation/Constraint/ReferenceAccessConstraintValidator.php
index ab8d64c228dfd7de9d504480946d5956d135777a..c57478197bbe5dcc3abeabae907df51a9c5fdae0 100644
--- a/core/lib/Drupal/Core/Entity/Plugin/Validation/Constraint/ReferenceAccessConstraintValidator.php
+++ b/core/lib/Drupal/Core/Entity/Plugin/Validation/Constraint/ReferenceAccessConstraintValidator.php
@@ -33,10 +33,10 @@ public function validate($value, Constraint $constraint) {
         $referenced_entities = $existing_entity->{$value->getFieldDefinition()->getName()}->referencedEntities();
         // Check permission if we are not already referencing the entity.
         foreach ($referenced_entities as $ref) {
-           if (isset($referenced_entities[$ref->id()])) {
-             $check_permission = FALSE;
-             break;
-           }
+          if (isset($referenced_entities[$ref->id()])) {
+            $check_permission = FALSE;
+            break;
+          }
         }
       }
       // We check that the current user had access to view any newly added
diff --git a/core/lib/Drupal/Core/Entity/Query/Sql/Query.php b/core/lib/Drupal/Core/Entity/Query/Sql/Query.php
index 2d5df2d1a24da0ca83bb72ddff9119c6c0ccedd7..78f831aff3fbdf8f3b8b1743af98bba2cc7098e7 100644
--- a/core/lib/Drupal/Core/Entity/Query/Sql/Query.php
+++ b/core/lib/Drupal/Core/Entity/Query/Sql/Query.php
@@ -225,7 +225,7 @@ protected function finish() {
     if ($this->range) {
       $this->sqlQuery->range($this->range['start'], $this->range['length']);
     }
-   foreach ($this->sqlGroupBy as $field) {
+    foreach ($this->sqlGroupBy as $field) {
       $this->sqlQuery->groupBy($field);
     }
     foreach ($this->sqlFields as $field) {
diff --git a/core/lib/Drupal/Core/Entity/entity.api.php b/core/lib/Drupal/Core/Entity/entity.api.php
index 36873845c759def2dc0f3b3fc6373e2abe213fa2..60ae7413ff51df4584d48f7cf35fa330252e8473 100644
--- a/core/lib/Drupal/Core/Entity/entity.api.php
+++ b/core/lib/Drupal/Core/Entity/entity.api.php
@@ -893,9 +893,9 @@ function hook_ENTITY_TYPE_storage_load(array $entities) {
  * @see hook_ENTITY_TYPE_presave()
  */
 function hook_entity_presave(Drupal\Core\Entity\EntityInterface $entity) {
- if ($entity instanceof ContentEntityInterface && $entity->isTranslatable()) {
-   $route_match = \Drupal::routeMatch();
-   \Drupal::service('content_translation.synchronizer')->synchronizeFields($entity, $entity->language()->getId(), $route_match->getParameter('source_langcode'));
+  if ($entity instanceof ContentEntityInterface && $entity->isTranslatable()) {
+    $route_match = \Drupal::routeMatch();
+    \Drupal::service('content_translation.synchronizer')->synchronizeFields($entity, $entity->language()->getId(), $route_match->getParameter('source_langcode'));
   }
 }
 
diff --git a/core/lib/Drupal/Core/Field/AllowedTagsXssTrait.php b/core/lib/Drupal/Core/Field/AllowedTagsXssTrait.php
index 4b6d710ce1397725e732cf4b909bff44100a76d6..427d7f407fc47f37559835cb659d80215c96db01 100644
--- a/core/lib/Drupal/Core/Field/AllowedTagsXssTrait.php
+++ b/core/lib/Drupal/Core/Field/AllowedTagsXssTrait.php
@@ -30,7 +30,7 @@ trait AllowedTagsXssTrait {
    *   valid UTF-8.
    */
   public function fieldFilterXss($string) {
-   return FieldFilteredMarkup::create($string);
+    return FieldFilteredMarkup::create($string);
   }
 
   /**
diff --git a/core/lib/Drupal/Core/Field/FieldItemList.php b/core/lib/Drupal/Core/Field/FieldItemList.php
index ebdb2762acb412cf18319fdcc505edf829bd2c41..97dd493195aff9010d3a564bcceda40ee77f722a 100644
--- a/core/lib/Drupal/Core/Field/FieldItemList.php
+++ b/core/lib/Drupal/Core/Field/FieldItemList.php
@@ -257,7 +257,7 @@ public function view($display_options = array()) {
   /**
    * {@inheritdoc}
    */
-   public function generateSampleItems($count = 1) {
+  public function generateSampleItems($count = 1) {
     $field_definition = $this->getFieldDefinition();
     $field_type_class = \Drupal::service('plugin.manager.field.field_type')->getPluginClass($field_definition->getType());
     for ($delta = 0; $delta < $count; $delta++) {
diff --git a/core/lib/Drupal/Core/Field/Plugin/Field/FieldType/EntityReferenceItem.php b/core/lib/Drupal/Core/Field/Plugin/Field/FieldType/EntityReferenceItem.php
index e8832f31adfd38c2d76cc52ed65e0bcae5badc43..398d260886bc4c540fe854608eddd9a8862d1e9f 100644
--- a/core/lib/Drupal/Core/Field/Plugin/Field/FieldType/EntityReferenceItem.php
+++ b/core/lib/Drupal/Core/Field/Plugin/Field/FieldType/EntityReferenceItem.php
@@ -617,7 +617,7 @@ public static function settingsAjaxSubmit($form, FormStateInterface $form_state)
     $form_state->setRebuild();
   }
 
-    /**
+  /**
    * {@inheritdoc}
    */
   public static function getPreconfiguredOptions() {
diff --git a/core/lib/Drupal/Core/File/MimeType/MimeTypeGuesser.php b/core/lib/Drupal/Core/File/MimeType/MimeTypeGuesser.php
index 72df780a8151442d2fcc5fec71a9d3e795fde777..85d0261631f3477666e6f142129d762d12492f2c 100644
--- a/core/lib/Drupal/Core/File/MimeType/MimeTypeGuesser.php
+++ b/core/lib/Drupal/Core/File/MimeType/MimeTypeGuesser.php
@@ -31,7 +31,7 @@ class MimeTypeGuesser implements MimeTypeGuesserInterface {
    */
   protected $sortedGuessers = NULL;
 
-   /**
+  /**
    * The stream wrapper manager.
    *
    * @var \Drupal\Core\StreamWrapper\StreamWrapperManagerInterface
diff --git a/core/lib/Drupal/Core/Form/FormState.php b/core/lib/Drupal/Core/Form/FormState.php
index ca7355dceb6153cab0f0a54539bd2fb5b624f4f1..33ca1fafba0668d115ee0aad85dbbea11d44dc9d 100644
--- a/core/lib/Drupal/Core/Form/FormState.php
+++ b/core/lib/Drupal/Core/Form/FormState.php
@@ -648,7 +648,7 @@ public function disableRedirect($no_redirect = TRUE) {
    * {@inheritdoc}
    */
   public function isRedirectDisabled() {
-   return $this->no_redirect;
+    return $this->no_redirect;
   }
 
   /**
diff --git a/core/lib/Drupal/Core/ImageToolkit/ImageToolkitOperationBase.php b/core/lib/Drupal/Core/ImageToolkit/ImageToolkitOperationBase.php
index af1b2c95dbd760d86830edb102fe0dfae0898306..2a1e61ec30e03031e4785645876ea8cc754aedaf 100644
--- a/core/lib/Drupal/Core/ImageToolkit/ImageToolkitOperationBase.php
+++ b/core/lib/Drupal/Core/ImageToolkit/ImageToolkitOperationBase.php
@@ -123,7 +123,7 @@ protected function prepareArguments(array $arguments) {
 
         // Use the default value if the argument is not passed in.
         if (!array_key_exists($id, $arguments)) {
-         $arguments[$id] = $argument['default'];
+          $arguments[$id] = $argument['default'];
         }
       }
     }
diff --git a/core/lib/Drupal/Core/Installer/Form/SiteSettingsForm.php b/core/lib/Drupal/Core/Installer/Form/SiteSettingsForm.php
index c6a3840e64fe725116bbb71c5e6355a6c152cf4f..f5d1c7fe5063a7bee4239b427bb37641ac90cb06 100644
--- a/core/lib/Drupal/Core/Installer/Form/SiteSettingsForm.php
+++ b/core/lib/Drupal/Core/Installer/Form/SiteSettingsForm.php
@@ -37,7 +37,7 @@ class SiteSettingsForm extends FormBase {
   public function __construct($site_path, RendererInterface $renderer) {
     $this->sitePath = $site_path;
     $this->renderer = $renderer;
-}
+  }
 
   /**
     * {@inheritdoc}
diff --git a/core/lib/Drupal/Core/Mail/MailFormatHelper.php b/core/lib/Drupal/Core/Mail/MailFormatHelper.php
index 080b32617ac8236e0466bc793e9a95a0b5880729..3dffe830c20479600cd2d9abb734fbca7821bbcc 100644
--- a/core/lib/Drupal/Core/Mail/MailFormatHelper.php
+++ b/core/lib/Drupal/Core/Mail/MailFormatHelper.php
@@ -202,8 +202,7 @@ public static function htmlToText($string, $allowed_tags = NULL) {
               // Ensure blank new-line.
               $chunk = '';
             }
-
-          // Fall-through.
+            // Intentional fall-through to the processing for '/li' and '/dd'.
           case '/li':
           case '/dd':
             array_pop($indent);
@@ -212,6 +211,7 @@ public static function htmlToText($string, $allowed_tags = NULL) {
           case '/h3':
           case '/h4':
             array_pop($indent);
+            // Intentional fall-through to the processing for '/h5' and '/h6'.
           case '/h5':
           case '/h6':
             // Ensure blank new-line.
diff --git a/core/lib/Drupal/Core/Mail/MailInterface.php b/core/lib/Drupal/Core/Mail/MailInterface.php
index 1435ff9c276bc51fc7413122f3dec59dbdcd9bd9..fbde1b86dc76ceebe2e01e78f90b9dfef16a7829 100644
--- a/core/lib/Drupal/Core/Mail/MailInterface.php
+++ b/core/lib/Drupal/Core/Mail/MailInterface.php
@@ -30,7 +30,7 @@ interface MailInterface {
    *
    * @see \Drupal\Core\Mail\MailManagerInterface
    */
-   public function format(array $message);
+  public function format(array $message);
 
   /**
    * Sends a message composed by \Drupal\Core\Mail\MailManagerInterface->mail().
@@ -60,6 +60,6 @@ public function format(array $message);
    * @return bool
    *   TRUE if the mail was successfully accepted for delivery, otherwise FALSE.
    */
-   public function mail(array $message);
+  public function mail(array $message);
 
 }
diff --git a/core/lib/Drupal/Core/Menu/ContextualLinkManager.php b/core/lib/Drupal/Core/Menu/ContextualLinkManager.php
index 29803ad5007ef3ab02d2fc8629e0741a97c55a34..e264036fc4c9e7f1b9553596ea464f1260f5aec1 100644
--- a/core/lib/Drupal/Core/Menu/ContextualLinkManager.php
+++ b/core/lib/Drupal/Core/Menu/ContextualLinkManager.php
@@ -126,11 +126,11 @@ protected function getDiscovery() {
   public function processDefinition(&$definition, $plugin_id) {
     parent::processDefinition($definition, $plugin_id);
 
-     // If there is no route name, this is a broken definition.
+    // If there is no route name, this is a broken definition.
     if (empty($definition['route_name'])) {
       throw new PluginException(sprintf('Contextual link plugin (%s) definition must include "route_name".', $plugin_id));
     }
-     // If there is no group name, this is a broken definition.
+    // If there is no group name, this is a broken definition.
     if (empty($definition['group'])) {
       throw new PluginException(sprintf('Contextual link plugin (%s) definition must include "group".', $plugin_id));
     }
diff --git a/core/lib/Drupal/Core/Menu/DefaultMenuLinkTreeManipulators.php b/core/lib/Drupal/Core/Menu/DefaultMenuLinkTreeManipulators.php
index 43c4468286c69611b817b4e980f0fb809cb7a170..71590832dd8a7157ad7d1a6694cdd0edd082cc43 100644
--- a/core/lib/Drupal/Core/Menu/DefaultMenuLinkTreeManipulators.php
+++ b/core/lib/Drupal/Core/Menu/DefaultMenuLinkTreeManipulators.php
@@ -37,7 +37,7 @@ class DefaultMenuLinkTreeManipulators {
    *
    * @var \Drupal\Core\Entity\Query\QueryFactory
    */
-   protected $queryFactory;
+  protected $queryFactory;
 
   /**
    * Constructs a \Drupal\Core\Menu\DefaultMenuLinkTreeManipulators object.
diff --git a/core/lib/Drupal/Core/Menu/LocalActionDefault.php b/core/lib/Drupal/Core/Menu/LocalActionDefault.php
index faa20a892770f74dc051b21359be8c768377ac51..bfa088e0adb924b5017fad705f6dda693cef4990 100644
--- a/core/lib/Drupal/Core/Menu/LocalActionDefault.php
+++ b/core/lib/Drupal/Core/Menu/LocalActionDefault.php
@@ -24,7 +24,7 @@ class LocalActionDefault extends PluginBase implements LocalActionInterface, Con
    *
    * @var \Drupal\Core\Routing\RouteProviderInterface
    */
-   protected $routeProvider;
+  protected $routeProvider;
 
   /**
    * Constructs a LocalActionDefault object.
diff --git a/core/lib/Drupal/Core/Menu/LocalTaskManager.php b/core/lib/Drupal/Core/Menu/LocalTaskManager.php
index ec1df5c2fa2d50b8cd0fc9e2f39c61335384f152..26b2ed5b164c8d73778fe727cce1fb356f74c213 100644
--- a/core/lib/Drupal/Core/Menu/LocalTaskManager.php
+++ b/core/lib/Drupal/Core/Menu/LocalTaskManager.php
@@ -158,7 +158,7 @@ protected function getDiscovery() {
    */
   public function processDefinition(&$definition, $plugin_id) {
     parent::processDefinition($definition, $plugin_id);
-     // If there is no route name, this is a broken definition.
+    // If there is no route name, this is a broken definition.
     if (empty($definition['route_name'])) {
       throw new PluginException(sprintf('Plugin (%s) definition must include "route_name"', $plugin_id));
     }
diff --git a/core/lib/Drupal/Core/Path/AliasManager.php b/core/lib/Drupal/Core/Path/AliasManager.php
index 0368d43c2a0f2307977b03428d1e06cfc0f5dc73..3a31917310d4aaaf19d36feb482a90d578aa6b19 100644
--- a/core/lib/Drupal/Core/Path/AliasManager.php
+++ b/core/lib/Drupal/Core/Path/AliasManager.php
@@ -283,7 +283,7 @@ protected function pathAliasWhitelistRebuild($path = NULL) {
     if (!empty($path)) {
       if ($this->whitelist->get(strtok($path, '/'))) {
         return;
-     }
+      }
     }
     $this->whitelist->clear();
   }
diff --git a/core/lib/Drupal/Core/Plugin/Context/ContextDefinition.php b/core/lib/Drupal/Core/Plugin/Context/ContextDefinition.php
index 37f7bbc914a7047ca33a6b4dcc2650161f8fbf7e..71cfaa1048ad97e71924a1b351a97aa86a7b684c 100644
--- a/core/lib/Drupal/Core/Plugin/Context/ContextDefinition.php
+++ b/core/lib/Drupal/Core/Plugin/Context/ContextDefinition.php
@@ -85,7 +85,7 @@ public static function create($data_type = 'any') {
    *
    * @param string $data_type
    *   The required data type.
-   * @param mixed string|null $label
+   * @param string|null $label
    *   The label of this context definition for the UI.
    * @param bool $required
    *   Whether the context definition is required.
@@ -245,7 +245,7 @@ public function getDataDefinition() {
       ->setDescription($this->getDescription())
       ->setRequired($this->isRequired());
     $constraints = $definition->getConstraints() + $this->getConstraints();
-      $definition->setConstraints($constraints);
+    $definition->setConstraints($constraints);
     return $definition;
   }
 
diff --git a/core/lib/Drupal/Core/Render/theme.api.php b/core/lib/Drupal/Core/Render/theme.api.php
index 61cafc33cc2f0b73f591327d75cca196fbb7a46c..322761eee868ec6ff128d398a43fcbfe9c0cbfb1 100644
--- a/core/lib/Drupal/Core/Render/theme.api.php
+++ b/core/lib/Drupal/Core/Render/theme.api.php
@@ -555,7 +555,7 @@ function hook_form_system_theme_settings_alter(&$form, \Drupal\Core\Form\FormSta
  *   The name of the theme hook.
  */
 function hook_preprocess(&$variables, $hook) {
- static $hooks;
+  static $hooks;
 
   // Add contextual links to the variables, if the user has permission.
 
diff --git a/core/lib/Drupal/Core/StreamWrapper/PublicStream.php b/core/lib/Drupal/Core/StreamWrapper/PublicStream.php
index 52f05e4db80ecaf9cf416777286e63f20c06886d..f2783530958eb8541d63b1b1caf35d792d8dc916 100644
--- a/core/lib/Drupal/Core/StreamWrapper/PublicStream.php
+++ b/core/lib/Drupal/Core/StreamWrapper/PublicStream.php
@@ -66,7 +66,7 @@ public function getExternalUrl() {
   public static function baseUrl() {
     $settings_base_url = Settings::get('file_public_base_url', '');
     if ($settings_base_url) {
-       return (string) $settings_base_url;
+      return (string) $settings_base_url;
     }
     else {
       return $GLOBALS['base_url'] . '/' . static::basePath();
diff --git a/core/lib/Drupal/Core/TypedData/DataDefinitionInterface.php b/core/lib/Drupal/Core/TypedData/DataDefinitionInterface.php
index 4ae187b34428df06a723fc5f6fccace9c7bc527e..64d779c317b91ad0bc6bd94ce77bd6c56b65c7b5 100644
--- a/core/lib/Drupal/Core/TypedData/DataDefinitionInterface.php
+++ b/core/lib/Drupal/Core/TypedData/DataDefinitionInterface.php
@@ -44,7 +44,7 @@ interface DataDefinitionInterface {
    *   If an unsupported data type gets passed to the class; e.g., 'string' to a
    *   definition class handling 'entity:* data types.
    */
-   public static function createFromDataType($data_type);
+  public static function createFromDataType($data_type);
 
   /**
    * Returns the data type of the data.
diff --git a/core/lib/Drupal/Core/Utility/ThemeRegistry.php b/core/lib/Drupal/Core/Utility/ThemeRegistry.php
index 919571c666c7a2629e284e2cf302dde7a88de434..8dbf42e242dfa2a9ce013a5adaeb4ceb3aac867e 100644
--- a/core/lib/Drupal/Core/Utility/ThemeRegistry.php
+++ b/core/lib/Drupal/Core/Utility/ThemeRegistry.php
@@ -53,7 +53,7 @@ function __construct($cid, CacheBackendInterface $cache, LockBackendInterface $l
     $this->tags = $tags;
     $this->persistable = $modules_loaded && \Drupal::hasRequest() && \Drupal::request()->isMethod('GET');
 
-     // @todo: Implement lazyload.
+    // @todo: Implement lazyload.
     $this->cacheLoaded = TRUE;
 
     if ($this->persistable && $cached = $this->cache->get($this->cid)) {
diff --git a/core/modules/aggregator/src/Entity/Item.php b/core/modules/aggregator/src/Entity/Item.php
index 330aacb5c401cae639e8ef13bb0f9933c3ded1ef..2a2c195ad2e352f89d2f808dd6cd9c98cf7c95ca 100644
--- a/core/modules/aggregator/src/Entity/Item.php
+++ b/core/modules/aggregator/src/Entity/Item.php
@@ -54,7 +54,7 @@ public static function baseFieldDefinitions(EntityTypeInterface $entity_type) {
       ->setDescription(t('The ID of the feed item.'));
 
     $fields['langcode']->setLabel(t('Language code'))
-    ->setDescription(t('The feed item language code.'));
+      ->setDescription(t('The feed item language code.'));
 
     $fields['fid'] = BaseFieldDefinition::create('entity_reference')
       ->setLabel(t('Source feed'))
diff --git a/core/modules/aggregator/src/FeedAccessControlHandler.php b/core/modules/aggregator/src/FeedAccessControlHandler.php
index 3f11da9031f2faf54d06d5775a922f7f53b914e5..334265a782b7217a6ea9e250dc17f1804d4b868b 100644
--- a/core/modules/aggregator/src/FeedAccessControlHandler.php
+++ b/core/modules/aggregator/src/FeedAccessControlHandler.php
@@ -21,11 +21,9 @@ protected function checkAccess(EntityInterface $entity, $operation, AccountInter
     switch ($operation) {
       case 'view':
         return AccessResult::allowedIfHasPermission($account, 'access news feeds');
-        break;
 
       default:
         return AccessResult::allowedIfHasPermission($account, 'administer news feeds');
-        break;
     }
   }
 
diff --git a/core/modules/aggregator/src/Plugin/Field/FieldFormatter/AggregatorTitleFormatter.php b/core/modules/aggregator/src/Plugin/Field/FieldFormatter/AggregatorTitleFormatter.php
index 346ea2626b9dc87c20f407d1541d0a99c4bd06b1..25e33e9774fcba8c63e8f8ef7f1c07481b61b392 100644
--- a/core/modules/aggregator/src/Plugin/Field/FieldFormatter/AggregatorTitleFormatter.php
+++ b/core/modules/aggregator/src/Plugin/Field/FieldFormatter/AggregatorTitleFormatter.php
@@ -60,17 +60,17 @@ public function viewElements(FieldItemListInterface $items, $langcode) {
     }
 
     foreach ($items as $delta => $item) {
-        if ($this->getSetting('display_as_link') && $url_string) {
-          $elements[$delta] = [
+      if ($this->getSetting('display_as_link') && $url_string) {
+        $elements[$delta] = [
             '#type' => 'link',
             '#title' => $item->value,
             '#url' => Url::fromUri($url_string),
-          ];
-        }
-        else {
-          $elements[$delta] = ['#markup' => $item->value];
-        }
+        ];
       }
+      else {
+        $elements[$delta] = ['#markup' => $item->value];
+      }
+    }
 
     return $elements;
   }
diff --git a/core/modules/block/src/Plugin/migrate/process/BlockTheme.php b/core/modules/block/src/Plugin/migrate/process/BlockTheme.php
index d040ce63140925e22dc3f7c03a394c1b5870b984..bc1d98b8d46a0a9052f4a7cdec9924d4a7dc594c 100644
--- a/core/modules/block/src/Plugin/migrate/process/BlockTheme.php
+++ b/core/modules/block/src/Plugin/migrate/process/BlockTheme.php
@@ -24,11 +24,11 @@ class BlockTheme extends ProcessPluginBase implements ContainerFactoryPluginInte
    */
   protected $configFactory;
 
- /**
-  * Contains the system.theme configuration object.
-  *
-  * @var \Drupal\Core\Config\Config
-  */
+  /**
+   * Contains the system.theme configuration object.
+   *
+   * @var \Drupal\Core\Config\Config
+   */
   protected $themeConfig;
 
   /**
diff --git a/core/modules/block/src/Tests/BlockCacheTest.php b/core/modules/block/src/Tests/BlockCacheTest.php
index f7745394fc7c89c07406ff45035237c67aa121b5..898858021e5f699a2876151894433e5170d2c554 100644
--- a/core/modules/block/src/Tests/BlockCacheTest.php
+++ b/core/modules/block/src/Tests/BlockCacheTest.php
@@ -63,7 +63,7 @@ protected function setUp() {
     $this->normalUserAlt->save();
 
     // Enable our test block.
-   $this->block = $this->drupalPlaceBlock('test_cache');
+    $this->block = $this->drupalPlaceBlock('test_cache');
   }
 
   /**
diff --git a/core/modules/block/src/Tests/BlockFormInBlockTest.php b/core/modules/block/src/Tests/BlockFormInBlockTest.php
index 73c75919f5c089036a3adfb93ceaef0df8517f06..20d24b21a393dcf2fe0d9c16c5a34c34c64ed8c4 100644
--- a/core/modules/block/src/Tests/BlockFormInBlockTest.php
+++ b/core/modules/block/src/Tests/BlockFormInBlockTest.php
@@ -25,7 +25,7 @@ protected function setUp() {
     parent::setUp();
 
     // Enable our test block.
-   $this->drupalPlaceBlock('test_form_in_block');
+    $this->drupalPlaceBlock('test_form_in_block');
   }
 
   /**
diff --git a/core/modules/block/tests/src/Kernel/Migrate/d7/MigrateBlockTest.php b/core/modules/block/tests/src/Kernel/Migrate/d7/MigrateBlockTest.php
index 49be0ee03ac92a503d1316e393f5647f14b88e9f..b98f46f1cf5de746e68018f146548fa9b1c6c65c 100644
--- a/core/modules/block/tests/src/Kernel/Migrate/d7/MigrateBlockTest.php
+++ b/core/modules/block/tests/src/Kernel/Migrate/d7/MigrateBlockTest.php
@@ -13,7 +13,7 @@
  */
 class MigrateBlockTest extends MigrateDrupal7TestBase {
 
- /**
+  /**
    * {@inheritdoc}
    */
   public static $modules = [
diff --git a/core/modules/book/src/Tests/BookTest.php b/core/modules/book/src/Tests/BookTest.php
index 7ebec63613a1366013d646414072102fcc304f84..015899295bc7ae894efecfb9466253e1d76beb6e 100644
--- a/core/modules/book/src/Tests/BookTest.php
+++ b/core/modules/book/src/Tests/BookTest.php
@@ -526,49 +526,49 @@ function testNavigationBlockOnAccessModuleInstalled() {
   /**
    * Tests the access for deleting top-level book nodes.
    */
-   function testBookDelete() {
-     $node_storage = $this->container->get('entity.manager')->getStorage('node');
-     $nodes = $this->createBook();
-     $this->drupalLogin($this->adminUser);
-     $edit = array();
-
-     // Test access to delete top-level and child book nodes.
-     $this->drupalGet('node/' . $this->book->id() . '/outline/remove');
-     $this->assertResponse('403', 'Deleting top-level book node properly forbidden.');
-     $this->drupalPostForm('node/' . $nodes[4]->id() . '/outline/remove', $edit, t('Remove'));
-     $node_storage->resetCache(array($nodes[4]->id()));
-     $node4 = $node_storage->load($nodes[4]->id());
-     $this->assertTrue(empty($node4->book), 'Deleting child book node properly allowed.');
-
-     // Delete all child book nodes and retest top-level node deletion.
-     foreach ($nodes as $node) {
-       $nids[] = $node->id();
-     }
-     entity_delete_multiple('node', $nids);
-     $this->drupalPostForm('node/' . $this->book->id() . '/outline/remove', $edit, t('Remove'));
-     $node_storage->resetCache(array($this->book->id()));
-     $node = $node_storage->load($this->book->id());
-     $this->assertTrue(empty($node->book), 'Deleting childless top-level book node properly allowed.');
-
-     // Tests directly deleting a book parent.
-     $nodes = $this->createBook();
-     $this->drupalLogin($this->adminUser);
-     $this->drupalGet($this->book->urlInfo('delete-form'));
-     $this->assertRaw(t('%title is part of a book outline, and has associated child pages. If you proceed with deletion, the child pages will be relocated automatically.', ['%title' => $this->book->label()]));
-     // Delete parent, and visit a child page.
-     $this->drupalPostForm($this->book->urlInfo('delete-form'), [], t('Delete'));
-     $this->drupalGet($nodes[0]->urlInfo());
-     $this->assertResponse(200);
-     $this->assertText($nodes[0]->label());
-     // The book parents should be updated.
-     $node_storage = \Drupal::entityTypeManager()->getStorage('node');
-     $node_storage->resetCache();
-     $child = $node_storage->load($nodes[0]->id());
-     $this->assertEqual($child->id(), $child->book['bid'], 'Child node book ID updated when parent is deleted.');
-     // 3rd-level children should now be 2nd-level.
-     $second = $node_storage->load($nodes[1]->id());
-     $this->assertEqual($child->id(), $second->book['bid'], '3rd-level child node is now second level when top-level node is deleted.');
-   }
+  function testBookDelete() {
+    $node_storage = $this->container->get('entity.manager')->getStorage('node');
+    $nodes = $this->createBook();
+    $this->drupalLogin($this->adminUser);
+    $edit = array();
+
+    // Test access to delete top-level and child book nodes.
+    $this->drupalGet('node/' . $this->book->id() . '/outline/remove');
+    $this->assertResponse('403', 'Deleting top-level book node properly forbidden.');
+    $this->drupalPostForm('node/' . $nodes[4]->id() . '/outline/remove', $edit, t('Remove'));
+    $node_storage->resetCache(array($nodes[4]->id()));
+    $node4 = $node_storage->load($nodes[4]->id());
+    $this->assertTrue(empty($node4->book), 'Deleting child book node properly allowed.');
+
+    // Delete all child book nodes and retest top-level node deletion.
+    foreach ($nodes as $node) {
+      $nids[] = $node->id();
+    }
+    entity_delete_multiple('node', $nids);
+    $this->drupalPostForm('node/' . $this->book->id() . '/outline/remove', $edit, t('Remove'));
+    $node_storage->resetCache(array($this->book->id()));
+    $node = $node_storage->load($this->book->id());
+    $this->assertTrue(empty($node->book), 'Deleting childless top-level book node properly allowed.');
+
+    // Tests directly deleting a book parent.
+    $nodes = $this->createBook();
+    $this->drupalLogin($this->adminUser);
+    $this->drupalGet($this->book->urlInfo('delete-form'));
+    $this->assertRaw(t('%title is part of a book outline, and has associated child pages. If you proceed with deletion, the child pages will be relocated automatically.', ['%title' => $this->book->label()]));
+    // Delete parent, and visit a child page.
+    $this->drupalPostForm($this->book->urlInfo('delete-form'), [], t('Delete'));
+    $this->drupalGet($nodes[0]->urlInfo());
+    $this->assertResponse(200);
+    $this->assertText($nodes[0]->label());
+    // The book parents should be updated.
+    $node_storage = \Drupal::entityTypeManager()->getStorage('node');
+    $node_storage->resetCache();
+    $child = $node_storage->load($nodes[0]->id());
+    $this->assertEqual($child->id(), $child->book['bid'], 'Child node book ID updated when parent is deleted.');
+    // 3rd-level children should now be 2nd-level.
+    $second = $node_storage->load($nodes[1]->id());
+    $this->assertEqual($child->id(), $second->book['bid'], '3rd-level child node is now second level when top-level node is deleted.');
+  }
 
   /**
    * Tests re-ordering of books.
diff --git a/core/modules/comment/src/Form/CommentAdminOverview.php b/core/modules/comment/src/Form/CommentAdminOverview.php
index dac62bd4b9f32805f3f5a4f00c940579ca01ca49..3966fca1bfcc88911678de8e0575404e519f9740 100644
--- a/core/modules/comment/src/Form/CommentAdminOverview.php
+++ b/core/modules/comment/src/Form/CommentAdminOverview.php
@@ -151,10 +151,10 @@ public function buildForm(array $form, FormStateInterface $form_state, $type = '
       'operations' => $this->t('Operations'),
     );
     $cids = $this->commentStorage->getQuery()
-     ->condition('status', $status)
-     ->tableSort($header)
-     ->pager(50)
-     ->execute();
+      ->condition('status', $status)
+      ->tableSort($header)
+      ->pager(50)
+      ->execute();
 
     /** @var $comments \Drupal\comment\CommentInterface[] */
     $comments = $this->commentStorage->loadMultiple($cids);
diff --git a/core/modules/comment/tests/src/Unit/CommentStatisticsUnitTest.php b/core/modules/comment/tests/src/Unit/CommentStatisticsUnitTest.php
index e9047543381ab62312fae1a4e8d6c0f930125e14..39b4cf0a07d816d12fd8f402f28e1c715fae561e 100644
--- a/core/modules/comment/tests/src/Unit/CommentStatisticsUnitTest.php
+++ b/core/modules/comment/tests/src/Unit/CommentStatisticsUnitTest.php
@@ -111,13 +111,12 @@ public function fetchObjectCallback() {
     switch ($this->calls_to_fetch) {
       case 1:
         return 'something';
-        break;
+
       case 2:
         return 'something-else';
-        break;
+
       default:
         return FALSE;
-        break;
     }
   }
 
diff --git a/core/modules/config_translation/src/ConfigEntityMapper.php b/core/modules/config_translation/src/ConfigEntityMapper.php
index 5ba4456ca580ebd4a76fdca9b9a22f068ce73f31..faf899100b201cc8fc985ffc0132073c03531d37 100644
--- a/core/modules/config_translation/src/ConfigEntityMapper.php
+++ b/core/modules/config_translation/src/ConfigEntityMapper.php
@@ -120,7 +120,7 @@ public function getEntity() {
     return $this->entity;
   }
 
-    /**
+  /**
    * Sets the entity instance for this mapper.
    *
    * This method can only be invoked when the concrete entity is known, that is
diff --git a/core/modules/contact/src/ContactFormEditForm.php b/core/modules/contact/src/ContactFormEditForm.php
index 473d31775900ac36f23c9fb45c8b04bdd78a2373..7747dadb65ef24adc5c11d72581780ce7b99c150 100644
--- a/core/modules/contact/src/ContactFormEditForm.php
+++ b/core/modules/contact/src/ContactFormEditForm.php
@@ -40,8 +40,8 @@ class ContactFormEditForm extends EntityForm implements ContainerInjectionInterf
    *   The email validator.
    */
   public function __construct(EmailValidator $email_validator, PathValidatorInterface $path_validator) {
-   $this->emailValidator = $email_validator;
-   $this->pathValidator = $path_validator;
+    $this->emailValidator = $email_validator;
+    $this->pathValidator = $path_validator;
   }
 
   /**
diff --git a/core/modules/contact/tests/drupal-7.contact.database.php b/core/modules/contact/tests/drupal-7.contact.database.php
index 494e430cf68b7cd0a307de63fdc6930ffa904906..115f83c17cff6072ff12ba95840a8e2126aab40e 100644
--- a/core/modules/contact/tests/drupal-7.contact.database.php
+++ b/core/modules/contact/tests/drupal-7.contact.database.php
@@ -23,11 +23,11 @@
   'weight',
   'selected'
 ))
-->values(array(
+  ->values(array(
   'category' => 'Upgrade test',
   'recipients' => 'test1@example.com,test2@example.com',
   'reply' => 'Test reply',
   'weight' => 1,
   'selected' => 1,
 ))
-->execute();
+  ->execute();
diff --git a/core/modules/datetime/datetime.module b/core/modules/datetime/datetime.module
index f25140f0b061560d021adea43de03b0f1441e841..107854199276ca00c750b05363dc73ea6b44ccac 100644
--- a/core/modules/datetime/datetime.module
+++ b/core/modules/datetime/datetime.module
@@ -39,7 +39,7 @@ function datetime_help($route_name, RouteMatchInterface $route_match) {
       $output .= '<dd>' . t('Dates can be displayed using the <em>Plain</em> or the <em>Default</em> formatter. The <em>Plain</em> formatter displays the date in the <a href="http://en.wikipedia.org/wiki/ISO_8601">ISO 8601</a> format. If you choose the <em>Default</em> formatter, you can choose a format from a predefined list that can be managed on the <a href=":date_format_list">Date and time formats</a> page.', array(':date_format_list' => \Drupal::url('entity.date_format.collection'))) . '</dd>';
       $output .= '</dl>';
       return $output;
-    }
+  }
 }
 
 /**
diff --git a/core/modules/datetime/src/Plugin/Field/FieldWidget/DateTimeDatelistWidget.php b/core/modules/datetime/src/Plugin/Field/FieldWidget/DateTimeDatelistWidget.php
index c88c5c8341c670784f092cb3d1fdd9333733f71e..8cdabf1396379a4759a5efb1e68b78afbf0810ac 100644
--- a/core/modules/datetime/src/Plugin/Field/FieldWidget/DateTimeDatelistWidget.php
+++ b/core/modules/datetime/src/Plugin/Field/FieldWidget/DateTimeDatelistWidget.php
@@ -61,16 +61,16 @@ public function formElement(FieldItemListInterface $items, $delta, array $elemen
         break;
     }
     switch ($time_type) {
-       case '24':
-         $date_part_order = array_merge($date_part_order, array('hour', 'minute'));
-         break;
+      case '24':
+        $date_part_order = array_merge($date_part_order, array('hour', 'minute'));
+        break;
 
-       case '12':
-         $date_part_order = array_merge($date_part_order, array('hour', 'minute', 'ampm'));
-         break;
+      case '12':
+        $date_part_order = array_merge($date_part_order, array('hour', 'minute', 'ampm'));
+        break;
 
-       case 'none':
-         break;
+      case 'none':
+        break;
     }
 
     $element['value'] = array(
diff --git a/core/modules/datetime/src/Tests/DateTimeFieldTest.php b/core/modules/datetime/src/Tests/DateTimeFieldTest.php
index ce598bfa2f36f6f12099b1dcf6bcb95e0286dca9..64576f38d01db245e25ac71826b8a2cb752225ed 100644
--- a/core/modules/datetime/src/Tests/DateTimeFieldTest.php
+++ b/core/modules/datetime/src/Tests/DateTimeFieldTest.php
@@ -631,7 +631,7 @@ function testDatelistWidget() {
     $this->drupalPostForm(NULL, $edit, t('Save'));
     $this->assertResponse(200);
     $this->assertOptionSelected("edit-$field_name-0-value-minute", '0', 'Correct minute selected.');
- }
+  }
 
   /**
    * The data provider for testing the validation of the datelist widget.
diff --git a/core/modules/dblog/src/Tests/DbLogTest.php b/core/modules/dblog/src/Tests/DbLogTest.php
index 90cb6c2bf396a7fe33b5aaed11fc809b66135099..886f7681e973112b5d453ba5f17b308bb5530988 100644
--- a/core/modules/dblog/src/Tests/DbLogTest.php
+++ b/core/modules/dblog/src/Tests/DbLogTest.php
@@ -236,14 +236,14 @@ protected function clearLogsEntries() {
    *   (optional) The log entry severity.
   */
   protected function filterLogsEntries($type = NULL, $severity = NULL) {
-     $edit = array();
-     if (!is_null($type)) {
-       $edit['type[]'] = $type;
-     }
-     if (!is_null($severity)) {
-       $edit['severity[]'] = $severity;
-     }
-     $this->drupalPostForm(NULL, $edit, t('Filter'));
+    $edit = array();
+    if (!is_null($type)) {
+      $edit['type[]'] = $type;
+    }
+    if (!is_null($severity)) {
+      $edit['severity[]'] = $severity;
+    }
+    $this->drupalPostForm(NULL, $edit, t('Filter'));
   }
 
   /**
diff --git a/core/modules/field/src/Plugin/migrate/source/d6/FieldInstancePerViewMode.php b/core/modules/field/src/Plugin/migrate/source/d6/FieldInstancePerViewMode.php
index 93ba4efad3d1db0225ccc2e5fb8808896ddbfd3e..2e1832e1b0a41a9c6408d84b7852f7626958b1a4 100644
--- a/core/modules/field/src/Plugin/migrate/source/d6/FieldInstancePerViewMode.php
+++ b/core/modules/field/src/Plugin/migrate/source/d6/FieldInstancePerViewMode.php
@@ -59,11 +59,11 @@ public function query() {
         'label',
         'display_settings',
         'widget_settings',
-    ))
-    ->fields('cnf', array(
+      ))
+      ->fields('cnf', array(
         'type',
         'module',
-    ));
+      ));
     $query->join('content_node_field', 'cnf', 'cnfi.field_name = cnf.field_name');
     $query->orderBy('cnfi.weight');
 
diff --git a/core/modules/field/src/Tests/EntityReference/EntityReferenceFieldTranslatedReferenceViewTest.php b/core/modules/field/src/Tests/EntityReference/EntityReferenceFieldTranslatedReferenceViewTest.php
index d93b2acc5c6f62da8d7afe5505080810f4d7b87e..f0856d37bb0671dc22fbfc2fdc1b70a9150be5fc 100644
--- a/core/modules/field/src/Tests/EntityReference/EntityReferenceFieldTranslatedReferenceViewTest.php
+++ b/core/modules/field/src/Tests/EntityReference/EntityReferenceFieldTranslatedReferenceViewTest.php
@@ -223,7 +223,7 @@ protected function setUpEntityReferenceField() {
       'bundle' => $this->referrerType->id(),
       'entity_type' => $this->testEntityTypeName,
     ])
-    ->save();
+      ->save();
     entity_get_form_display($this->testEntityTypeName, $this->referrerType->id(), 'default')
       ->setComponent($this->referenceFieldName, array(
         'type' => 'entity_reference_autocomplete',
diff --git a/core/modules/field_ui/src/Form/FieldConfigEditForm.php b/core/modules/field_ui/src/Form/FieldConfigEditForm.php
index 827bf1b918a605592931712a1b71e5943ad0b4c8..ff6d157117edf07c64a7a75149dc5f4f0b741325 100644
--- a/core/modules/field_ui/src/Form/FieldConfigEditForm.php
+++ b/core/modules/field_ui/src/Form/FieldConfigEditForm.php
@@ -167,7 +167,7 @@ public function submitForm(array &$form, FormStateInterface $form_state) {
       $default_value = $items->defaultValuesFormSubmit($form['default_value'], $form, $form_state);
     }
     $this->entity->setDefaultValue($default_value);
-}
+  }
 
   /**
    * {@inheritdoc}
diff --git a/core/modules/file/src/Entity/File.php b/core/modules/file/src/Entity/File.php
index b82d5a836528c946d48fa1fb8817158b81ae9fa7..cd7a65897f720017bf2ceec7a4f1dc538de3406c 100644
--- a/core/modules/file/src/Entity/File.php
+++ b/core/modules/file/src/Entity/File.php
@@ -229,7 +229,7 @@ public static function baseFieldDefinitions(EntityTypeInterface $entity_type) {
     $fields['uuid']->setDescription(t('The file UUID.'));
 
     $fields['langcode']->setLabel(t('Language code'))
-     ->setDescription(t('The file language code.'));
+      ->setDescription(t('The file language code.'));
 
     $fields['uid'] = BaseFieldDefinition::create('entity_reference')
       ->setLabel(t('User ID'))
diff --git a/core/modules/filter/src/Plugin/FilterInterface.php b/core/modules/filter/src/Plugin/FilterInterface.php
index 18f1fde893e3d7520e849430cd0def7061ee1618..0b7fcf0dc3db4d55252f315eea9ebce3a8219170 100644
--- a/core/modules/filter/src/Plugin/FilterInterface.php
+++ b/core/modules/filter/src/Plugin/FilterInterface.php
@@ -77,25 +77,25 @@
  */
 interface FilterInterface extends ConfigurablePluginInterface, PluginInspectionInterface {
 
-   /**
-    * Non-HTML markup language filters that generate HTML.
-    */
-   const TYPE_MARKUP_LANGUAGE = 0;
+  /**
+   * Non-HTML markup language filters that generate HTML.
+   */
+  const TYPE_MARKUP_LANGUAGE = 0;
 
-   /**
-    * HTML tag and attribute restricting filters to prevent XSS attacks.
-    */
-   const TYPE_HTML_RESTRICTOR = 1;
+  /**
+   * HTML tag and attribute restricting filters to prevent XSS attacks.
+   */
+  const TYPE_HTML_RESTRICTOR = 1;
 
-   /**
-    * Reversible transformation filters.
-    */
-   const TYPE_TRANSFORM_REVERSIBLE = 2;
+  /**
+   * Reversible transformation filters.
+   */
+  const TYPE_TRANSFORM_REVERSIBLE = 2;
 
-   /**
-    * Irreversible transformation filters.
-    */
-   const TYPE_TRANSFORM_IRREVERSIBLE = 3;
+  /**
+   * Irreversible transformation filters.
+   */
+  const TYPE_TRANSFORM_IRREVERSIBLE = 3;
 
   /**
    * Returns the processing type of this filter plugin.
diff --git a/core/modules/image/src/Tests/ImageFieldWidgetTest.php b/core/modules/image/src/Tests/ImageFieldWidgetTest.php
index ea2332dd3599b2c98d8f7dc1e55ccc39bd1bef5d..52d9e4d5ca652a935b9a2c923ad97435bb39e5a3 100644
--- a/core/modules/image/src/Tests/ImageFieldWidgetTest.php
+++ b/core/modules/image/src/Tests/ImageFieldWidgetTest.php
@@ -13,7 +13,7 @@ class ImageFieldWidgetTest extends ImageFieldTestBase {
    * Tests file widget element.
    */
   public function testWidgetElement() {
-     // Check for image widget in add/node/article page
+    // Check for image widget in add/node/article page
     $field_name = strtolower($this->randomMachineName());
     $min_resolution = 50;
     $max_resolution = 100;
diff --git a/core/modules/image/src/Tests/ImageStylesPathAndUrlTest.php b/core/modules/image/src/Tests/ImageStylesPathAndUrlTest.php
index 1fed32f3b39d4b865402c0bb66ccc705e34021eb..d03bc3bc998f58c59e72352c7aab9774a5b28509 100644
--- a/core/modules/image/src/Tests/ImageStylesPathAndUrlTest.php
+++ b/core/modules/image/src/Tests/ImageStylesPathAndUrlTest.php
@@ -62,9 +62,9 @@ function testImageStyleUrlAndPathPrivate() {
   /**
    * Tests an image style URL with the "public://" scheme and unclean URLs.
    */
-   function testImageStyleUrlAndPathPublicUnclean() {
-     $this->doImageStyleUrlAndPathTests('public', FALSE);
-   }
+  function testImageStyleUrlAndPathPublicUnclean() {
+    $this->doImageStyleUrlAndPathTests('public', FALSE);
+  }
 
   /**
    * Tests an image style URL with the "private://" schema and unclean URLs.
diff --git a/core/modules/image/tests/src/Kernel/Migrate/d6/MigrateImageCacheTest.php b/core/modules/image/tests/src/Kernel/Migrate/d6/MigrateImageCacheTest.php
index 28e11bdf6ee105009e844a516a2c110ac40b0c25..98db7b18ccf6abf2ee2171ef0b117dbb7af7ca8e 100644
--- a/core/modules/image/tests/src/Kernel/Migrate/d6/MigrateImageCacheTest.php
+++ b/core/modules/image/tests/src/Kernel/Migrate/d6/MigrateImageCacheTest.php
@@ -86,64 +86,64 @@ public function testPassingMigration() {
   /**
    * Test that missing actions causes failures.
    */
-   public function testMissingEffectPlugin() {
-     Database::getConnection('default', 'migrate')->insert("imagecache_action")
+  public function testMissingEffectPlugin() {
+    Database::getConnection('default', 'migrate')->insert("imagecache_action")
        ->fields([
-         'presetid',
-         'weight',
-         'module',
-         'action',
-         'data',
-       ])
+       'presetid',
+       'weight',
+       'module',
+       'action',
+       'data',
+     ])
        ->values([
-         'presetid' => '1',
-         'weight' => '0',
-         'module' => 'imagecache',
-         'action' => 'imagecache_deprecated_scale',
-         'data' => 'a:3:{s:3:"fit";s:7:"outside";s:5:"width";s:3:"200";s:6:"height";s:3:"200";}',
-       ])->execute();
-
-     $this->startCollectingMessages();
-     $this->executeMigration('d6_imagecache_presets');
-     $messages = $this->migration->getIdMap()->getMessageIterator();
-     $count = 0;
-     foreach ($messages as $message) {
-       $count++;
-       $this->assertEqual($message->message, 'The "image_deprecated_scale" plugin does not exist.');
-       $this->assertEqual($message->level, MigrationInterface::MESSAGE_ERROR);
-     }
-     // There should be only the one message.
-     $this->assertEqual($count, 1);
+       'presetid' => '1',
+       'weight' => '0',
+       'module' => 'imagecache',
+       'action' => 'imagecache_deprecated_scale',
+       'data' => 'a:3:{s:3:"fit";s:7:"outside";s:5:"width";s:3:"200";s:6:"height";s:3:"200";}',
+     ])->execute();
+
+    $this->startCollectingMessages();
+    $this->executeMigration('d6_imagecache_presets');
+    $messages = $this->migration->getIdMap()->getMessageIterator();
+    $count = 0;
+    foreach ($messages as $message) {
+      $count++;
+      $this->assertEqual($message->message, 'The "image_deprecated_scale" plugin does not exist.');
+      $this->assertEqual($message->level, MigrationInterface::MESSAGE_ERROR);
+    }
+    // There should be only the one message.
+    $this->assertEqual($count, 1);
   }
 
   /**
    * Test that missing action's causes failures.
    */
-   public function testInvalidCropValues() {
-     Database::getConnection('default', 'migrate')->insert("imagecache_action")
+  public function testInvalidCropValues() {
+    Database::getConnection('default', 'migrate')->insert("imagecache_action")
        ->fields([
-         'presetid',
-         'weight',
-         'module',
-         'action',
-         'data',
-       ])
+       'presetid',
+       'weight',
+       'module',
+       'action',
+       'data',
+     ])
        ->values([
-         'presetid' => '1',
-         'weight' => '0',
-         'module' => 'imagecache',
-         'action' => 'imagecache_crop',
-         'data' => serialize([
-           'xoffset' => '10',
-           'yoffset' => '10',
-         ]),
-       ])->execute();
-
-     $this->startCollectingMessages();
-     $this->executeMigration('d6_imagecache_presets');
-     $this->assertEqual(['error' => [
-       'The Drupal 8 image crop effect does not support numeric values for x and y offsets. Use keywords to set crop effect offsets instead.'
-     ]], $this->migrateMessages);
+       'presetid' => '1',
+       'weight' => '0',
+       'module' => 'imagecache',
+       'action' => 'imagecache_crop',
+       'data' => serialize([
+         'xoffset' => '10',
+         'yoffset' => '10',
+       ]),
+     ])->execute();
+
+    $this->startCollectingMessages();
+    $this->executeMigration('d6_imagecache_presets');
+    $this->assertEqual(['error' => [
+     'The Drupal 8 image crop effect does not support numeric values for x and y offsets. Use keywords to set crop effect offsets instead.'
+    ]], $this->migrateMessages);
   }
 
   /**
diff --git a/core/modules/link/src/Plugin/migrate/cckfield/LinkField.php b/core/modules/link/src/Plugin/migrate/cckfield/LinkField.php
index 47b383084a049c1d8631098201f16d476c4de609..314e8df8a6e7c6f34ecaf85a779ed713bc691f62 100644
--- a/core/modules/link/src/Plugin/migrate/cckfield/LinkField.php
+++ b/core/modules/link/src/Plugin/migrate/cckfield/LinkField.php
@@ -38,11 +38,11 @@ public function getFieldFormatterMap() {
    * {@inheritdoc}
    */
   public function processCckFieldValues(MigrationInterface $migration, $field_name, $data) {
-      $process = [
-        'plugin' => 'd6_cck_link',
-        'source' => $field_name,
-      ];
-      $migration->mergeProcessOfProperty($field_name, $process);
+    $process = [
+      'plugin' => 'd6_cck_link',
+      'source' => $field_name,
+    ];
+    $migration->mergeProcessOfProperty($field_name, $process);
   }
 
 }
diff --git a/core/modules/locale/src/StringDatabaseStorage.php b/core/modules/locale/src/StringDatabaseStorage.php
index 01a0544e458ee30917e7809c83c40408aaf0d571..058c68960b61144c7864d66c9c59d1d368399760 100644
--- a/core/modules/locale/src/StringDatabaseStorage.php
+++ b/core/modules/locale/src/StringDatabaseStorage.php
@@ -175,9 +175,9 @@ protected function checkVersion($string, $version) {
     if ($string->getId() && $string->getVersion() != $version) {
       $string->setVersion($version);
       $this->connection->update('locales_source', $this->options)
-      ->condition('lid', $string->getId())
-      ->fields(array('version' => $version))
-      ->execute();
+        ->condition('lid', $string->getId())
+        ->fields(array('version' => $version))
+        ->execute();
     }
   }
 
diff --git a/core/modules/menu_link_content/src/Entity/MenuLinkContent.php b/core/modules/menu_link_content/src/Entity/MenuLinkContent.php
index 1dcd1cd20a54e2b927d9d1dfa95edcb2df249a31..d23f876bea42dff249581864facd08f5f065b9d3 100644
--- a/core/modules/menu_link_content/src/Entity/MenuLinkContent.php
+++ b/core/modules/menu_link_content/src/Entity/MenuLinkContent.php
@@ -333,7 +333,7 @@ public static function baseFieldDefinitions(EntityTypeInterface $entity_type) {
         'type' => 'boolean',
         'weight' => 0,
       ))
-    ->setDisplayOptions('form', array(
+      ->setDisplayOptions('form', array(
         'settings' => array('display_label' => TRUE),
         'weight' => 0,
       ));
diff --git a/core/modules/menu_ui/src/Tests/MenuTest.php b/core/modules/menu_ui/src/Tests/MenuTest.php
index f640cc749a6c4130db66ee14b8cecbd59a273b33..e9464ab23467ad354173ab2b858af8335edf7913 100644
--- a/core/modules/menu_ui/src/Tests/MenuTest.php
+++ b/core/modules/menu_ui/src/Tests/MenuTest.php
@@ -916,7 +916,7 @@ private function verifyAccess($response = 200) {
 
     // View tools menu customization page.
     $this->drupalGet('admin/structure/menu/manage/' . $this->menu->id());
-        $this->assertResponse($response);
+    $this->assertResponse($response);
     if ($response == 200) {
       $this->assertText(t('Tools'), 'Tools menu page was displayed');
     }
diff --git a/core/modules/migrate/src/Event/MigratePreRowSaveEvent.php b/core/modules/migrate/src/Event/MigratePreRowSaveEvent.php
index 5e563bbd1080cf01f0209a4568f1ad246aaaf45b..98a1c0a53edf66b0903355b8681b7d0b8808dbeb 100644
--- a/core/modules/migrate/src/Event/MigratePreRowSaveEvent.php
+++ b/core/modules/migrate/src/Event/MigratePreRowSaveEvent.php
@@ -28,7 +28,7 @@ class MigratePreRowSaveEvent extends EventBase {
    * @param \Drupal\migrate\Row $row
    */
   public function __construct(MigrationInterface $migration, MigrateMessageInterface $message, Row $row) {
-     parent::__construct($migration, $message);
+    parent::__construct($migration, $message);
     $this->row = $row;
   }
 
diff --git a/core/modules/migrate/src/MigrateExecutable.php b/core/modules/migrate/src/MigrateExecutable.php
index 7368acd96441ca229f9f0d21bdaf607455931689..50bf0181c96a5821f036f773014497f0d753b471 100644
--- a/core/modules/migrate/src/MigrateExecutable.php
+++ b/core/modules/migrate/src/MigrateExecutable.php
@@ -185,11 +185,17 @@ public function import() {
     }
     catch (RequirementsException $e) {
       $this->message->display(
-        $this->t('Migration @id did not meet the requirements. @message @requirements', array(
-          '@id' => $this->migration->id(),
-          '@message' => $e->getMessage(),
-          '@requirements' => $e->getRequirementsString(),
-        )), 'error');
+        $this->t(
+          'Migration @id did not meet the requirements. @message @requirements',
+          array(
+            '@id' => $this->migration->id(),
+            '@message' => $e->getMessage(),
+            '@requirements' => $e->getRequirementsString(),
+          )
+        ),
+        'error'
+      );
+
       return MigrationInterface::RESULT_FAILED;
     }
 
@@ -476,30 +482,44 @@ protected function memoryExceeded() {
     }
     if ($pct_memory > $threshold) {
       $this->message->display(
-        $this->t('Memory usage is @usage (@pct% of limit @limit), reclaiming memory.',
-          array('@pct' => round($pct_memory * 100),
-                '@usage' => $this->formatSize($usage),
-                '@limit' => $this->formatSize($this->memoryLimit))),
-        'warning');
+        $this->t(
+          'Memory usage is @usage (@pct% of limit @limit), reclaiming memory.',
+          array(
+            '@pct' => round($pct_memory * 100),
+            '@usage' => $this->formatSize($usage),
+            '@limit' => $this->formatSize($this->memoryLimit),
+          )
+        ),
+        'warning'
+      );
       $usage = $this->attemptMemoryReclaim();
       $pct_memory = $usage / $this->memoryLimit;
       // Use a lower threshold - we don't want to be in a situation where we keep
       // coming back here and trimming a tiny amount
       if ($pct_memory > (0.90 * $threshold)) {
         $this->message->display(
-          $this->t('Memory usage is now @usage (@pct% of limit @limit), not enough reclaimed, starting new batch',
-            array('@pct' => round($pct_memory * 100),
-                  '@usage' => $this->formatSize($usage),
-                  '@limit' => $this->formatSize($this->memoryLimit))),
-          'warning');
+          $this->t(
+            'Memory usage is now @usage (@pct% of limit @limit), not enough reclaimed, starting new batch',
+            array(
+              '@pct' => round($pct_memory * 100),
+              '@usage' => $this->formatSize($usage),
+              '@limit' => $this->formatSize($this->memoryLimit),
+            )
+          ),
+          'warning'
+        );
         return TRUE;
       }
       else {
         $this->message->display(
-          $this->t('Memory usage is now @usage (@pct% of limit @limit), reclaimed enough, continuing',
-            array('@pct' => round($pct_memory * 100),
-                  '@usage' => $this->formatSize($usage),
-                  '@limit' => $this->formatSize($this->memoryLimit))),
+          $this->t(
+            'Memory usage is now @usage (@pct% of limit @limit), reclaimed enough, continuing',
+            array(
+              '@pct' => round($pct_memory * 100),
+              '@usage' => $this->formatSize($usage),
+              '@limit' => $this->formatSize($this->memoryLimit),
+            )
+          ),
           'warning');
         return FALSE;
       }
diff --git a/core/modules/migrate/tests/src/Unit/MigrateSourceTest.php b/core/modules/migrate/tests/src/Unit/MigrateSourceTest.php
index 5e2a06e3f1fa37529c023e7dfa998e346aa825f8..2b7f12f6d1b493e42dd55f7ddd36b20615c6c01d 100644
--- a/core/modules/migrate/tests/src/Unit/MigrateSourceTest.php
+++ b/core/modules/migrate/tests/src/Unit/MigrateSourceTest.php
@@ -170,7 +170,7 @@ public function testCount() {
     $this->assertEquals(-1, $source->count());
   }
 
-   /**
+  /**
    * Test that the key can be set for the count cache.
    *
    * @covers ::count
diff --git a/core/modules/migrate_drupal/src/Plugin/migrate/source/DrupalSqlBase.php b/core/modules/migrate_drupal/src/Plugin/migrate/source/DrupalSqlBase.php
index 87bd66d3770ae597a63b93b6498e3111d0ea4490..2c3230fc8d7c77f5bc50d12d3a00469c42fe7237 100644
--- a/core/modules/migrate_drupal/src/Plugin/migrate/source/DrupalSqlBase.php
+++ b/core/modules/migrate_drupal/src/Plugin/migrate/source/DrupalSqlBase.php
@@ -23,7 +23,7 @@ abstract class DrupalSqlBase extends SqlBase implements ContainerFactoryPluginIn
 
   use DependencyTrait;
 
-   /**
+  /**
    * The contents of the system table.
    *
    * @var array
@@ -53,12 +53,12 @@ public function __construct(array $configuration, $plugin_id, $plugin_definition
   }
 
   /**
-    * Retrieves all system data information from origin system.
-    *
-    * @return array
-    *   List of system table information keyed by type and name.
-    */
-   public function getSystemData() {
+   * Retrieves all system data information from origin system.
+   *
+   * @return array
+   *   List of system table information keyed by type and name.
+   */
+  public function getSystemData() {
     if (!isset($this->systemData)) {
       $this->systemData = array();
       try {
diff --git a/core/modules/node/node.module b/core/modules/node/node.module
index 8451c58fec279d7a2a2658ad72a103f9e62d9100..5c86a137aeae1a3233c2ac27970651f9cb006cb7 100644
--- a/core/modules/node/node.module
+++ b/core/modules/node/node.module
@@ -320,7 +320,7 @@ function node_type_load($name) {
  *   A Body field object.
  */
 function node_add_body_field(NodeTypeInterface $type, $label = 'Body') {
-   // Add or remove the body field, as needed.
+  // Add or remove the body field, as needed.
   $field_storage = FieldStorageConfig::loadByName('node', 'body');
   $field = FieldConfig::loadByName('node', $type->id(), 'body');
   if (empty($field)) {
@@ -751,7 +751,7 @@ function node_get_recent($number = 10) {
       // If not, restrict the query to published nodes.
       $query->condition('status', NODE_PUBLISHED);
     }
-   }
+  }
   $nids = $query
     ->sort('changed', 'DESC')
     ->range(0, $number)
diff --git a/core/modules/node/src/NodeTypeAccessControlHandler.php b/core/modules/node/src/NodeTypeAccessControlHandler.php
index ad82232037657e58fe2d4a6be82d61181b6bd124..b14bae3666d25c1072aad109f437803ffe5d833c 100644
--- a/core/modules/node/src/NodeTypeAccessControlHandler.php
+++ b/core/modules/node/src/NodeTypeAccessControlHandler.php
@@ -21,7 +21,6 @@ protected function checkAccess(EntityInterface $entity, $operation, AccountInter
     switch ($operation) {
       case 'view':
         return AccessResult::allowedIfHasPermission($account, 'access content');
-        break;
 
       case 'delete':
         if ($entity->isLocked()) {
@@ -34,7 +33,7 @@ protected function checkAccess(EntityInterface $entity, $operation, AccountInter
 
       default:
         return parent::checkAccess($entity, $operation, $account);
-        break;
+
     }
   }
 
diff --git a/core/modules/node/src/Tests/NodeAccessLanguageAwareCombinationTest.php b/core/modules/node/src/Tests/NodeAccessLanguageAwareCombinationTest.php
index acf9217c40d4fe3dbdcd2999562b7651b0fe288c..1ee5bc27ad14e9adde1e38fbe60bfcfb666c6ad2 100644
--- a/core/modules/node/src/Tests/NodeAccessLanguageAwareCombinationTest.php
+++ b/core/modules/node/src/Tests/NodeAccessLanguageAwareCombinationTest.php
@@ -254,9 +254,9 @@ function testNodeAccessLanguageAwareCombination() {
 
     // Query with no language specified. The fallback (hu or und) will be used.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->webUser)
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->webUser)
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // Four nodes should be returned with public Hungarian translations or the
@@ -269,10 +269,10 @@ function testNodeAccessLanguageAwareCombination() {
 
     // Query with Hungarian (hu) specified.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->webUser)
-    ->addMetaData('langcode', 'hu')
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->webUser)
+      ->addMetaData('langcode', 'hu')
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // Three nodes should be returned (with public Hungarian translations).
@@ -283,10 +283,10 @@ function testNodeAccessLanguageAwareCombination() {
 
     // Query with Catalan (ca) specified.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->webUser)
-    ->addMetaData('langcode', 'ca')
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->webUser)
+      ->addMetaData('langcode', 'ca')
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // Three nodes should be returned (with public Catalan translations).
@@ -297,10 +297,10 @@ function testNodeAccessLanguageAwareCombination() {
 
     // Query with German (de) specified.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->webUser)
-    ->addMetaData('langcode', 'de')
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->webUser)
+      ->addMetaData('langcode', 'de')
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // There are no nodes with German translations, so no results are returned.
@@ -309,9 +309,9 @@ function testNodeAccessLanguageAwareCombination() {
     // Query the nodes table as admin user (full access) with the node access
     // tag and no specific langcode.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->adminUser)
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->adminUser)
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // All nodes are returned.
@@ -320,10 +320,10 @@ function testNodeAccessLanguageAwareCombination() {
     // Query the nodes table as admin user (full access) with the node access
     // tag and langcode de.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->adminUser)
-    ->addMetaData('langcode', 'de')
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->adminUser)
+      ->addMetaData('langcode', 'de')
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // Even though there is no German translation, all nodes are returned
diff --git a/core/modules/node/src/Tests/NodeAccessLanguageAwareTest.php b/core/modules/node/src/Tests/NodeAccessLanguageAwareTest.php
index ea5a8832f34e5bcffb07d20a5219b0f7fc4a4a6b..0609b7ba97357f55fa77106ac197dcd609864d8d 100644
--- a/core/modules/node/src/Tests/NodeAccessLanguageAwareTest.php
+++ b/core/modules/node/src/Tests/NodeAccessLanguageAwareTest.php
@@ -195,9 +195,9 @@ function testNodeAccessLanguageAware() {
 
     // Query with no language specified. The fallback (hu) will be used.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->webUser)
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->webUser)
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // Three nodes should be returned:
@@ -211,10 +211,10 @@ function testNodeAccessLanguageAware() {
 
     // Query with Hungarian (hu) specified.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->webUser)
-    ->addMetaData('langcode', 'hu')
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->webUser)
+      ->addMetaData('langcode', 'hu')
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // Two nodes should be returned: the node with both translations public, and
@@ -225,10 +225,10 @@ function testNodeAccessLanguageAware() {
 
     // Query with Catalan (ca) specified.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->webUser)
-    ->addMetaData('langcode', 'ca')
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->webUser)
+      ->addMetaData('langcode', 'ca')
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // Two nodes should be returned: the node with both translations public, and
@@ -239,10 +239,10 @@ function testNodeAccessLanguageAware() {
 
     // Query with German (de) specified.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->webUser)
-    ->addMetaData('langcode', 'de')
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->webUser)
+      ->addMetaData('langcode', 'de')
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // There are no nodes with German translations, so no results are returned.
@@ -251,9 +251,9 @@ function testNodeAccessLanguageAware() {
     // Query the nodes table as admin user (full access) with the node access
     // tag and no specific langcode.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->adminUser)
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->adminUser)
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // All nodes are returned.
@@ -262,10 +262,10 @@ function testNodeAccessLanguageAware() {
     // Query the nodes table as admin user (full access) with the node access
     // tag and langcode de.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $this->adminUser)
-    ->addMetaData('langcode', 'de')
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $this->adminUser)
+      ->addMetaData('langcode', 'de')
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // Even though there is no German translation, all nodes are returned
diff --git a/core/modules/node/src/Tests/NodeAccessLanguageTest.php b/core/modules/node/src/Tests/NodeAccessLanguageTest.php
index 5d55a5b90a7fb39fe74e1304400afb8d6c588aba..e0393a0a18f83213d4df10f639d984759ae19934 100644
--- a/core/modules/node/src/Tests/NodeAccessLanguageTest.php
+++ b/core/modules/node/src/Tests/NodeAccessLanguageTest.php
@@ -204,9 +204,9 @@ function testNodeAccessQueryTag() {
     // Query the nodes table as the web user with the node access tag and no
     // specific langcode.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $web_user)
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $web_user)
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // The public node and no language node should be returned. Because no
@@ -218,10 +218,10 @@ function testNodeAccessQueryTag() {
     // Query the nodes table as the web user with the node access tag and
     // langcode de.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $web_user)
-    ->addMetaData('langcode', 'de')
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $web_user)
+      ->addMetaData('langcode', 'de')
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // Because no nodes are created in German, no nodes are returned.
@@ -230,9 +230,9 @@ function testNodeAccessQueryTag() {
     // Query the nodes table as admin user (full access) with the node access
     // tag and no specific langcode.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $admin_user)
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $admin_user)
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // All nodes are returned.
@@ -241,10 +241,10 @@ function testNodeAccessQueryTag() {
     // Query the nodes table as admin user (full access) with the node access
     // tag and langcode de.
     $select = db_select('node', 'n')
-    ->fields('n', array('nid'))
-    ->addMetaData('account', $admin_user)
-    ->addMetaData('langcode', 'de')
-    ->addTag('node_access');
+      ->fields('n', array('nid'))
+      ->addMetaData('account', $admin_user)
+      ->addMetaData('langcode', 'de')
+      ->addTag('node_access');
     $nids = $select->execute()->fetchAllAssoc('nid');
 
     // All nodes are returned because node access tag is not invoked when the
diff --git a/core/modules/node/src/Tests/NodeFieldMultilingualTest.php b/core/modules/node/src/Tests/NodeFieldMultilingualTest.php
index 9beae5df8588195e16258a90d63e643fc282e262..3bd1a51ef6d6f9fdff4797fc040ab6f80154b351 100644
--- a/core/modules/node/src/Tests/NodeFieldMultilingualTest.php
+++ b/core/modules/node/src/Tests/NodeFieldMultilingualTest.php
@@ -119,7 +119,7 @@ function testMultilingualDisplaySettings() {
 
     // Check if node body is showed.
     $this->drupalGet('node/' . $node->id());
-     $body = $this->xpath('//article[contains(concat(" ", normalize-space(@class), " "), :node-class)]//div[contains(concat(" ", normalize-space(@class), " "), :content-class)]/descendant::p', array(
+    $body = $this->xpath('//article[contains(concat(" ", normalize-space(@class), " "), :node-class)]//div[contains(concat(" ", normalize-space(@class), " "), :content-class)]/descendant::p', array(
       ':node-class' => ' node ',
       ':content-class' => 'node__content',
     ));
diff --git a/core/modules/options/src/Plugin/Field/FieldType/ListItemBase.php b/core/modules/options/src/Plugin/Field/FieldType/ListItemBase.php
index 55108d5d61963a2c01d97fc7dbcd080e2e0e3166..aaea32f9b156ad5dfc77a9ee41f240f12c4f62d1 100644
--- a/core/modules/options/src/Plugin/Field/FieldType/ListItemBase.php
+++ b/core/modules/options/src/Plugin/Field/FieldType/ListItemBase.php
@@ -65,11 +65,11 @@ public function getSettableOptions(AccountInterface $account = NULL) {
   /**
    * {@inheritdoc}
    */
-   public static function generateSampleValue(FieldDefinitionInterface $field_definition) {
-     $allowed_options = options_allowed_values($field_definition->getFieldStorageDefinition());
-     $values['value'] = array_rand($allowed_options);
-     return $values;
-   }
+  public static function generateSampleValue(FieldDefinitionInterface $field_definition) {
+    $allowed_options = options_allowed_values($field_definition->getFieldStorageDefinition());
+    $values['value'] = array_rand($allowed_options);
+    return $values;
+  }
 
   /**
    * {@inheritdoc}
diff --git a/core/modules/rest/src/Tests/RESTTestBase.php b/core/modules/rest/src/Tests/RESTTestBase.php
index 4f8a0f196e73dc3ae16937a15035c58bd839f8fe..a7fb62ac62986e441661256212d8a2295923a37c 100644
--- a/core/modules/rest/src/Tests/RESTTestBase.php
+++ b/core/modules/rest/src/Tests/RESTTestBase.php
@@ -115,15 +115,15 @@ protected function httpRequest($url, $method, $body = NULL, $mime_type = NULL, $
         );
         break;
 
-        case 'HEAD':
-          $curl_options = array(
-            CURLOPT_HTTPGET => FALSE,
-            CURLOPT_CUSTOMREQUEST => 'HEAD',
-            CURLOPT_URL => $url,
-            CURLOPT_NOBODY => TRUE,
-            CURLOPT_HTTPHEADER => array('Accept: ' . $mime_type),
-          );
-          break;
+      case 'HEAD':
+        $curl_options = array(
+          CURLOPT_HTTPGET => FALSE,
+          CURLOPT_CUSTOMREQUEST => 'HEAD',
+          CURLOPT_URL => $url,
+          CURLOPT_NOBODY => TRUE,
+          CURLOPT_HTTPHEADER => array('Accept: ' . $mime_type),
+        );
+        break;
 
       case 'POST':
         $curl_options = array(
diff --git a/core/modules/rest/src/Tests/Views/StyleSerializerTest.php b/core/modules/rest/src/Tests/Views/StyleSerializerTest.php
index 50e0e7472c2a0a8046c3d69fffcd7d36620af2a1..4c004fcafcdd673b7c212ad4f26fff7e209afc74 100644
--- a/core/modules/rest/src/Tests/Views/StyleSerializerTest.php
+++ b/core/modules/rest/src/Tests/Views/StyleSerializerTest.php
@@ -353,7 +353,7 @@ public function testResponseFormatConfiguration() {
     $this->drupalGetWithFormat('test/serialize/field', 'json');
     $this->assertHeader('content-type', 'application/json');
     $this->assertResponse(406, 'A 406 response was returned when JSON was requested.');
-     // Should return a 200.
+    // Should return a 200.
     $this->drupalGetWithFormat('test/serialize/field', 'xml');
     $this->assertHeader('content-type', 'text/xml; charset=UTF-8');
     $this->assertResponse(200, 'A 200 response was returned when XML was requested.');
@@ -551,7 +551,7 @@ public function testLivePreview() {
     // We set up a request so it looks like an request in the live preview.
     $request = new Request();
     $request->query->add([MainContentViewSubscriber::WRAPPER_FORMAT => 'drupal_ajax']);
-      /** @var \Symfony\Component\HttpFoundation\RequestStack $request_stack */
+    /** @var \Symfony\Component\HttpFoundation\RequestStack $request_stack */
     $request_stack = \Drupal::service('request_stack');
     $request_stack->push($request);
 
diff --git a/core/modules/serialization/src/Normalizer/NormalizerBase.php b/core/modules/serialization/src/Normalizer/NormalizerBase.php
index 934093ec2e33b756c4f8480582152f18552c5a79..90d9b752581649e90c35e251f3fff3daf5bfa688 100644
--- a/core/modules/serialization/src/Normalizer/NormalizerBase.php
+++ b/core/modules/serialization/src/Normalizer/NormalizerBase.php
@@ -72,6 +72,6 @@ protected function checkFormat($format = NULL) {
     }
 
     return in_array($format, (array) $this->format);
-   }
+  }
 
 }
diff --git a/core/modules/shortcut/src/Form/ShortcutSetDeleteForm.php b/core/modules/shortcut/src/Form/ShortcutSetDeleteForm.php
index 1a3cbf208c3764e98fbbd8965c35dc3dbb451287..3c732d6bc8cddf0511d1930651451eb6c7ed0cb2 100644
--- a/core/modules/shortcut/src/Form/ShortcutSetDeleteForm.php
+++ b/core/modules/shortcut/src/Form/ShortcutSetDeleteForm.php
@@ -70,6 +70,6 @@ public function buildForm(array $form, FormStateInterface $form_state) {
     );
 
     return parent::buildForm($form, $form_state);
-   }
+  }
 
 }
diff --git a/core/modules/simpletest/src/TestBase.php b/core/modules/simpletest/src/TestBase.php
index 4258f803881260a86303d605a11740ebdd6e334a..944810a4aa8e09fc62968aa3fa157c92b89508b0 100644
--- a/core/modules/simpletest/src/TestBase.php
+++ b/core/modules/simpletest/src/TestBase.php
@@ -527,7 +527,7 @@ protected function getAssertionCall() {
     // The first element is the call. The second element is the caller.
     // We skip calls that occurred in one of the methods of our base classes
     // or in an assertion function.
-   while (($caller = $backtrace[1]) &&
+    while (($caller = $backtrace[1]) &&
          ((isset($caller['class']) && isset($this->skipClasses[$caller['class']])) ||
            substr($caller['function'], 0, 6) == 'assert')) {
       // We remove that call.
diff --git a/core/modules/system/src/Tests/Ajax/AjaxFormPageCacheTest.php b/core/modules/system/src/Tests/Ajax/AjaxFormPageCacheTest.php
index 04a7e981e115c0b72c3e56bc5ca84c8877044214..a537b73e81dcb9c284937eb37237a12786b1fcdc 100644
--- a/core/modules/system/src/Tests/Ajax/AjaxFormPageCacheTest.php
+++ b/core/modules/system/src/Tests/Ajax/AjaxFormPageCacheTest.php
@@ -33,61 +33,61 @@ protected function getFormBuildId() {
    * Create a simple form, then submit the form via AJAX to change to it.
    */
   public function testSimpleAJAXFormValue() {
-   $this->drupalGet('ajax_forms_test_get_form');
-   $this->assertEqual($this->drupalGetHeader('X-Drupal-Cache'), 'MISS', 'Page was not cached.');
-   $build_id_initial = $this->getFormBuildId();
+    $this->drupalGet('ajax_forms_test_get_form');
+    $this->assertEqual($this->drupalGetHeader('X-Drupal-Cache'), 'MISS', 'Page was not cached.');
+    $build_id_initial = $this->getFormBuildId();
 
-   $edit = ['select' => 'green'];
-   $commands = $this->drupalPostAjaxForm(NULL, $edit, 'select');
-   $build_id_first_ajax = $this->getFormBuildId();
-   $this->assertNotEqual($build_id_initial, $build_id_first_ajax, 'Build id is changed in the simpletest-DOM on first AJAX submission');
-   $expected = [
-     'command' => 'update_build_id',
-     'old' => $build_id_initial,
-     'new' => $build_id_first_ajax,
-   ];
-   $this->assertCommand($commands, $expected, 'Build id change command issued on first AJAX submission');
+    $edit = ['select' => 'green'];
+    $commands = $this->drupalPostAjaxForm(NULL, $edit, 'select');
+    $build_id_first_ajax = $this->getFormBuildId();
+    $this->assertNotEqual($build_id_initial, $build_id_first_ajax, 'Build id is changed in the simpletest-DOM on first AJAX submission');
+    $expected = [
+      'command' => 'update_build_id',
+      'old' => $build_id_initial,
+      'new' => $build_id_first_ajax,
+    ];
+    $this->assertCommand($commands, $expected, 'Build id change command issued on first AJAX submission');
 
-   $edit = ['select' => 'red'];
-   $commands = $this->drupalPostAjaxForm(NULL, $edit, 'select');
-   $build_id_second_ajax = $this->getFormBuildId();
-   $this->assertNotEqual($build_id_first_ajax, $build_id_second_ajax, 'Build id changes on subsequent AJAX submissions');
-   $expected = [
-     'command' => 'update_build_id',
-     'old' => $build_id_first_ajax,
-     'new' => $build_id_second_ajax,
-   ];
-   $this->assertCommand($commands, $expected, 'Build id change command issued on subsequent AJAX submissions');
+    $edit = ['select' => 'red'];
+    $commands = $this->drupalPostAjaxForm(NULL, $edit, 'select');
+    $build_id_second_ajax = $this->getFormBuildId();
+    $this->assertNotEqual($build_id_first_ajax, $build_id_second_ajax, 'Build id changes on subsequent AJAX submissions');
+    $expected = [
+      'command' => 'update_build_id',
+      'old' => $build_id_first_ajax,
+      'new' => $build_id_second_ajax,
+    ];
+    $this->assertCommand($commands, $expected, 'Build id change command issued on subsequent AJAX submissions');
 
-   // Repeat the test sequence but this time with a page loaded from the cache.
-   $this->drupalGet('ajax_forms_test_get_form');
-   $this->assertEqual($this->drupalGetHeader('X-Drupal-Cache'), 'HIT', 'Page was cached.');
-   $build_id_from_cache_initial = $this->getFormBuildId();
-   $this->assertEqual($build_id_initial, $build_id_from_cache_initial, 'Build id is the same as on the first request');
+    // Repeat the test sequence but this time with a page loaded from the cache.
+    $this->drupalGet('ajax_forms_test_get_form');
+    $this->assertEqual($this->drupalGetHeader('X-Drupal-Cache'), 'HIT', 'Page was cached.');
+    $build_id_from_cache_initial = $this->getFormBuildId();
+    $this->assertEqual($build_id_initial, $build_id_from_cache_initial, 'Build id is the same as on the first request');
 
-   $edit = ['select' => 'green'];
-   $commands = $this->drupalPostAjaxForm(NULL, $edit, 'select');
-   $build_id_from_cache_first_ajax = $this->getFormBuildId();
-   $this->assertNotEqual($build_id_from_cache_initial, $build_id_from_cache_first_ajax, 'Build id is changed in the simpletest-DOM on first AJAX submission');
-   $this->assertNotEqual($build_id_first_ajax, $build_id_from_cache_first_ajax, 'Build id from first user is not reused');
-   $expected = [
-     'command' => 'update_build_id',
-     'old' => $build_id_from_cache_initial,
-     'new' => $build_id_from_cache_first_ajax,
-   ];
-   $this->assertCommand($commands, $expected, 'Build id change command issued on first AJAX submission');
+    $edit = ['select' => 'green'];
+    $commands = $this->drupalPostAjaxForm(NULL, $edit, 'select');
+    $build_id_from_cache_first_ajax = $this->getFormBuildId();
+    $this->assertNotEqual($build_id_from_cache_initial, $build_id_from_cache_first_ajax, 'Build id is changed in the simpletest-DOM on first AJAX submission');
+    $this->assertNotEqual($build_id_first_ajax, $build_id_from_cache_first_ajax, 'Build id from first user is not reused');
+    $expected = [
+      'command' => 'update_build_id',
+      'old' => $build_id_from_cache_initial,
+      'new' => $build_id_from_cache_first_ajax,
+    ];
+    $this->assertCommand($commands, $expected, 'Build id change command issued on first AJAX submission');
 
-   $edit = ['select' => 'red'];
-   $commands = $this->drupalPostAjaxForm(NULL, $edit, 'select');
-   $build_id_from_cache_second_ajax = $this->getFormBuildId();
-   $this->assertNotEqual($build_id_from_cache_first_ajax, $build_id_from_cache_second_ajax, 'Build id changes on subsequent AJAX submissions');
-   $expected = [
-     'command' => 'update_build_id',
-     'old' => $build_id_from_cache_first_ajax,
-     'new' => $build_id_from_cache_second_ajax,
-   ];
-   $this->assertCommand($commands, $expected, 'Build id change command issued on subsequent AJAX submissions');
- }
+    $edit = ['select' => 'red'];
+    $commands = $this->drupalPostAjaxForm(NULL, $edit, 'select');
+    $build_id_from_cache_second_ajax = $this->getFormBuildId();
+    $this->assertNotEqual($build_id_from_cache_first_ajax, $build_id_from_cache_second_ajax, 'Build id changes on subsequent AJAX submissions');
+    $expected = [
+      'command' => 'update_build_id',
+      'old' => $build_id_from_cache_first_ajax,
+      'new' => $build_id_from_cache_second_ajax,
+    ];
+    $this->assertCommand($commands, $expected, 'Build id change command issued on subsequent AJAX submissions');
+  }
 
   /**
    * Tests a form that uses an #ajax callback.
diff --git a/core/modules/system/src/Tests/Form/ElementsVerticalTabsTest.php b/core/modules/system/src/Tests/Form/ElementsVerticalTabsTest.php
index 3de1867b88d36846e3b50051c3988056efe759fa..2e630cccae067a829cf81519844c626f6d0fc66d 100644
--- a/core/modules/system/src/Tests/Form/ElementsVerticalTabsTest.php
+++ b/core/modules/system/src/Tests/Form/ElementsVerticalTabsTest.php
@@ -70,9 +70,9 @@ function testWrapperNotShownWhenEmpty() {
     $this->assertFalse(isset($wrapper[0]), 'Vertical tab wrappers are not displayed to unprivileged users.');
   }
 
- /**
-  * Ensures that default vertical tab is correctly selected.
-  */
+  /**
+   * Ensures that default vertical tab is correctly selected.
+   */
   function testDefaultTab() {
     $this->drupalGet('form_test/vertical-tabs');
     $this->assertFieldByName('vertical_tabs__active_tab', 'edit-tab3', t('The default vertical tab is correctly selected.'));
diff --git a/core/modules/system/src/Tests/Theme/EngineTwigTest.php b/core/modules/system/src/Tests/Theme/EngineTwigTest.php
index a6b7acfe76550140b51de38c70db559578689123..ae08fc83527b5bb455d95e2b9441fa8f0c56d425 100644
--- a/core/modules/system/src/Tests/Theme/EngineTwigTest.php
+++ b/core/modules/system/src/Tests/Theme/EngineTwigTest.php
@@ -72,7 +72,7 @@ public function testTwigUrlGenerator() {
   public function testTwigLinkGenerator() {
     $this->drupalGet('twig-theme-test/link-generator');
 
-     /** @var \Drupal\Core\Utility\LinkGenerator $link_generator */
+    /** @var \Drupal\Core\Utility\LinkGenerator $link_generator */
     $link_generator = $this->container->get('link_generator');
 
     $expected = [
diff --git a/core/modules/system/src/Tests/Update/UpdatePathTestBase.php b/core/modules/system/src/Tests/Update/UpdatePathTestBase.php
index 82169ad7cb76c46135547d662189a3c6295449d7..2596cdf4da538633c5234cd2a4c0ec4dff027114 100644
--- a/core/modules/system/src/Tests/Update/UpdatePathTestBase.php
+++ b/core/modules/system/src/Tests/Update/UpdatePathTestBase.php
@@ -45,7 +45,7 @@ abstract class UpdatePathTestBase extends WebTestBase {
    */
   protected static $modules = [];
 
- /**
+  /**
    * The file path(s) to the dumped database(s) to load into the child site.
    *
    * The file system/tests/fixtures/update/drupal-8.bare.standard.php.gz is
diff --git a/core/modules/system/src/Tests/Update/UpdateScriptTest.php b/core/modules/system/src/Tests/Update/UpdateScriptTest.php
index d788636129df6064b0ab70f302dca0be213baf65..b80ef82e3bc994fc9a2c0b7f2a7e56cdbb4e141b 100644
--- a/core/modules/system/src/Tests/Update/UpdateScriptTest.php
+++ b/core/modules/system/src/Tests/Update/UpdateScriptTest.php
@@ -232,9 +232,9 @@ function testMaintenanceModeUpdateFunctionality() {
     $this->assertEqual($final_maintenance_mode, $initial_maintenance_mode, 'Maintenance mode should not have changed after database updates.');
   }
 
- /**
-  * Tests perfoming updates with update.php in a multilingual environment.
-  */
+  /**
+   * Tests perfoming updates with update.php in a multilingual environment.
+   */
   function testSuccessfulMultilingualUpdateFunctionality() {
     // Add some custom languages.
     foreach (array('aa', 'bb') as $language_code) {
@@ -242,7 +242,7 @@ function testSuccessfulMultilingualUpdateFunctionality() {
           'id' => $language_code,
           'label' => $this->randomMachineName(),
         ))->save();
-     }
+    }
 
     $config = \Drupal::service('config.factory')->getEditable('language.negotiation');
     // Ensure path prefix is used to determine the language.
diff --git a/core/modules/system/system.install b/core/modules/system/system.install
index 178110517bed88397249ff21394e19438b923e97..154a55bf0f769c9d985ca231dd33fe1c866bf598 100644
--- a/core/modules/system/system.install
+++ b/core/modules/system/system.install
@@ -1219,10 +1219,10 @@ function system_update_8005() {
 
       case 'seven':
         $name = 'block.block.seven_local_actions';
-          $values = [
-            'id' => 'seven_local_actions',
-            'weight' => -10,
-          ] + $local_actions_default_settings;
+        $values = [
+          'id' => 'seven_local_actions',
+          'weight' => -10,
+        ] + $local_actions_default_settings;
         _system_update_create_block($name, $theme_name, $values);
 
         $name = 'block.block.seven_primary_local_tasks';
diff --git a/core/modules/system/tests/fixtures/update/drupal-8.views-entity-views-data-2455125.php b/core/modules/system/tests/fixtures/update/drupal-8.views-entity-views-data-2455125.php
index 6ff4d81181971a9c9ee8c8386129f4934c0949d9..2fcda10af17ba2fb24653d2603736c61270833e1 100644
--- a/core/modules/system/tests/fixtures/update/drupal-8.views-entity-views-data-2455125.php
+++ b/core/modules/system/tests/fixtures/update/drupal-8.views-entity-views-data-2455125.php
@@ -17,16 +17,16 @@
 $views_configs[] = Yaml::decode(file_get_contents(__DIR__ . '/drupal-8.views-entity-views-data-2455125.yml'));
 
 foreach ($views_configs as $views_config) {
-$connection->insert('config')
-  ->fields(array(
+  $connection->insert('config')
+    ->fields(array(
       'collection',
       'name',
       'data',
     ))
-  ->values(array(
+    ->values(array(
       'collection' => '',
       'name' => 'views.view.' . $views_config['id'],
       'data' => serialize($views_config),
     ))
-  ->execute();
+    ->execute();
 }
diff --git a/core/modules/system/tests/modules/common_test/src/Render/MainContent/JsonRenderer.php b/core/modules/system/tests/modules/common_test/src/Render/MainContent/JsonRenderer.php
index babf0314547e83ce26cc37ee025c79f9e5356cd3..bcecfbc5f4ba9a6b399991cbafc7b278bf91a038 100644
--- a/core/modules/system/tests/modules/common_test/src/Render/MainContent/JsonRenderer.php
+++ b/core/modules/system/tests/modules/common_test/src/Render/MainContent/JsonRenderer.php
@@ -46,19 +46,19 @@ public function __construct(TitleResolverInterface $title_resolver, RendererInte
    * {@inheritdoc}
    */
   public function renderResponse(array $main_content, Request $request, RouteMatchInterface $route_match) {
-      $json = [];
+    $json = [];
 
-      $json['content'] = (string) $this->renderer->renderRoot($main_content);
-      if (!empty($main_content['#title'])) {
-        $json['title'] = (string) $main_content['#title'];
-      }
-      else {
-        $json['title'] = (string) $this->titleResolver->getTitle($request, $route_match->getRouteObject());
-      }
+    $json['content'] = (string) $this->renderer->renderRoot($main_content);
+    if (!empty($main_content['#title'])) {
+      $json['title'] = (string) $main_content['#title'];
+    }
+    else {
+      $json['title'] = (string) $this->titleResolver->getTitle($request, $route_match->getRouteObject());
+    }
 
-      $response = new CacheableJsonResponse($json, 200);
-      $response->addCacheableDependency(CacheableMetadata::createFromRenderArray($main_content));
-      return $response;
+    $response = new CacheableJsonResponse($json, 200);
+    $response->addCacheableDependency(CacheableMetadata::createFromRenderArray($main_content));
+    return $response;
   }
 
 }
diff --git a/core/modules/system/tests/modules/httpkernel_test/src/HttpKernel/TestMiddleware.php b/core/modules/system/tests/modules/httpkernel_test/src/HttpKernel/TestMiddleware.php
index 47842b71b31449d155c17ea1d834ed361c3174a0..f9e9849ef360e95fcc3a4136ceded0b6deab7aa8 100644
--- a/core/modules/system/tests/modules/httpkernel_test/src/HttpKernel/TestMiddleware.php
+++ b/core/modules/system/tests/modules/httpkernel_test/src/HttpKernel/TestMiddleware.php
@@ -10,12 +10,12 @@
  */
 class TestMiddleware implements HttpKernelInterface {
 
- /**
-  * The decorated kernel.
-  *
-  * @var \Symfony\Component\HttpKernel\HttpKernelInterface
-  */
- protected $kernel;
+  /**
+   * The decorated kernel.
+   *
+   * @var \Symfony\Component\HttpKernel\HttpKernelInterface
+   */
+  protected $kernel;
 
   /**
    * An optional argument.
@@ -35,21 +35,21 @@ class TestMiddleware implements HttpKernelInterface {
   public function __construct(HttpKernelInterface $kernel, $optional_argument = NULL) {
     $this->kernel = $kernel;
     $this->optionalArgument = $optional_argument;
- }
-
- /**
-  * {@inheritdoc}
-  */
- public function handle(Request $request, $type = self::MASTER_REQUEST, $catch = TRUE) {
-   $request->attributes->set('_hello', 'world');
-   if ($request->attributes->has('_optional_argument')) {
-     $request->attributes->set('_previous_optional_argument', $request->attributes->get('_optional_argument'));
-   }
-   elseif (isset($this->optionalArgument)) {
-     $request->attributes->set('_optional_argument', $this->optionalArgument);
-   }
-
-   return $this->kernel->handle($request, $type, $catch);
- }
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public function handle(Request $request, $type = self::MASTER_REQUEST, $catch = TRUE) {
+    $request->attributes->set('_hello', 'world');
+    if ($request->attributes->has('_optional_argument')) {
+      $request->attributes->set('_previous_optional_argument', $request->attributes->get('_optional_argument'));
+    }
+    elseif (isset($this->optionalArgument)) {
+      $request->attributes->set('_optional_argument', $this->optionalArgument);
+    }
+
+    return $this->kernel->handle($request, $type, $catch);
+  }
 
 }
diff --git a/core/modules/system/tests/modules/plugin_test/src/Plugin/DefaultsTestPluginManager.php b/core/modules/system/tests/modules/plugin_test/src/Plugin/DefaultsTestPluginManager.php
index 457dbe500426cf38a45ce96b12e94323e9cdcd31..eda8f8845eaf3e72347784faa89c174e2d699fed 100644
--- a/core/modules/system/tests/modules/plugin_test/src/Plugin/DefaultsTestPluginManager.php
+++ b/core/modules/system/tests/modules/plugin_test/src/Plugin/DefaultsTestPluginManager.php
@@ -12,12 +12,12 @@
  */
 class DefaultsTestPluginManager extends DefaultPluginManager {
 
- /**
-  * Constructs a new DefaultsTestPluginManager instance.
-  *
-  * @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler
-  *   The module handler.
-  */
+  /**
+   * Constructs a new DefaultsTestPluginManager instance.
+   *
+   * @param \Drupal\Core\Extension\ModuleHandlerInterface $module_handler
+   *   The module handler.
+   */
   public function __construct(ModuleHandlerInterface $module_handler) {
     // Create the object that can be used to return definitions for all the
     // plugins available for this type. Most real plugin managers use a richer
diff --git a/core/modules/system/tests/src/Kernel/Scripts/DbCommandBaseTest.php b/core/modules/system/tests/src/Kernel/Scripts/DbCommandBaseTest.php
index c11770d490328ade4301ec50973a0758032470e7..1aa2f667abf50c83e603b30aba0cd6bf2781aaa0 100644
--- a/core/modules/system/tests/src/Kernel/Scripts/DbCommandBaseTest.php
+++ b/core/modules/system/tests/src/Kernel/Scripts/DbCommandBaseTest.php
@@ -99,10 +99,10 @@ public function testPrefix() {
     $this->assertEquals('extra2', $command->getDatabaseConnection($command_tester->getInput())->tablePrefix());
 
     // This breaks simpletest cleanup.
-//    $command_tester->execute([
-//      '--prefix' => 'notsimpletest',
-//    ]);
-//    $this->assertEquals('notsimpletest', $command->getDatabaseConnection($command_tester->getInput())->tablePrefix());
+    //    $command_tester->execute([
+    //      '--prefix' => 'notsimpletest',
+    //    ]);
+    //    $this->assertEquals('notsimpletest', $command->getDatabaseConnection($command_tester->getInput())->tablePrefix());
   }
 
 }
diff --git a/core/modules/taxonomy/src/TermAccessControlHandler.php b/core/modules/taxonomy/src/TermAccessControlHandler.php
index 7a6a9910774012c0b4a653a793a61ae5fbf41453..04c2c4f3fb7d1aba9ddba9971643a0c4bd6ea73f 100644
--- a/core/modules/taxonomy/src/TermAccessControlHandler.php
+++ b/core/modules/taxonomy/src/TermAccessControlHandler.php
@@ -21,15 +21,12 @@ protected function checkAccess(EntityInterface $entity, $operation, AccountInter
     switch ($operation) {
       case 'view':
         return AccessResult::allowedIfHasPermission($account, 'access content');
-        break;
 
       case 'update':
         return AccessResult::allowedIfHasPermissions($account, ["edit terms in {$entity->bundle()}", 'administer taxonomy'], 'OR');
-        break;
 
       case 'delete':
         return AccessResult::allowedIfHasPermissions($account, ["delete terms in {$entity->bundle()}", 'administer taxonomy'], 'OR');
-        break;
 
       default:
         // No opinion.
diff --git a/core/modules/taxonomy/tests/src/Kernel/ForwardRevisionTest.php b/core/modules/taxonomy/tests/src/Kernel/ForwardRevisionTest.php
index 6f751b12a1191d89472422739fd0c309cc4f27cd..abc0846fc507030b71ec55dfd15337bf08eba57e 100644
--- a/core/modules/taxonomy/tests/src/Kernel/ForwardRevisionTest.php
+++ b/core/modules/taxonomy/tests/src/Kernel/ForwardRevisionTest.php
@@ -113,9 +113,9 @@ public function testTaxonomyIndexWithForwardRevision() {
 
   protected function getTaxonomyIndex() {
     return \Drupal::database()->select('taxonomy_index')
-     ->fields('taxonomy_index')
-     ->execute()
-     ->fetchAllAssoc('nid');
+      ->fields('taxonomy_index')
+      ->execute()
+      ->fetchAllAssoc('nid');
   }
 
 }
diff --git a/core/modules/text/src/Plugin/migrate/cckfield/TextField.php b/core/modules/text/src/Plugin/migrate/cckfield/TextField.php
index cc4c1ecf7e42d7c3fe36919757710fae8b3e9cfb..89475ffd220bf01b12d9692594555edb00d96a13 100644
--- a/core/modules/text/src/Plugin/migrate/cckfield/TextField.php
+++ b/core/modules/text/src/Plugin/migrate/cckfield/TextField.php
@@ -120,7 +120,6 @@ public function getFieldType(Row $row) {
           return 'text_long';
         default:
           return parent::getFieldType($row);
-          break;
       }
     }
   }
diff --git a/core/modules/toolbar/tests/modules/toolbar_test/toolbar_test.module b/core/modules/toolbar/tests/modules/toolbar_test/toolbar_test.module
index 78c2d090b05210706105cc67f9dac727a8347961..4a82ca7cb2e9735bd84299d10f37075d1a07be7a 100644
--- a/core/modules/toolbar/tests/modules/toolbar_test/toolbar_test.module
+++ b/core/modules/toolbar/tests/modules/toolbar_test/toolbar_test.module
@@ -12,7 +12,7 @@
  */
 function toolbar_test_toolbar() {
 
-    $items['testing'] = array(
+  $items['testing'] = array(
     '#type' => 'toolbar_item',
     'tab' => array(
       '#type' => 'link',
diff --git a/core/modules/tour/src/Tests/TourCacheTagsTest.php b/core/modules/tour/src/Tests/TourCacheTagsTest.php
index 4e0972dcf0887ff8dc9a16cba87e0f4ee8efb59f..4f2164e1884cddc8dcaf9c6a9c16fcc3a538c2bd 100644
--- a/core/modules/tour/src/Tests/TourCacheTagsTest.php
+++ b/core/modules/tour/src/Tests/TourCacheTagsTest.php
@@ -29,7 +29,7 @@ protected function setUp() {
     // Give anonymous users permission to view nodes, so that we can verify the
     // cache tags of cached versions of node pages.
     Role::load(RoleInterface::ANONYMOUS_ID)->grantPermission('access tour')
-     ->save();
+      ->save();
   }
 
   /**
diff --git a/core/modules/update/src/Form/UpdateReady.php b/core/modules/update/src/Form/UpdateReady.php
index ba686143f3e8937c86d1c7aaf92cc758c04c9f4a..c8f64a3ee3c3efedf37a3c883e2cea00bf8c26cb 100644
--- a/core/modules/update/src/Form/UpdateReady.php
+++ b/core/modules/update/src/Form/UpdateReady.php
@@ -42,7 +42,7 @@ class UpdateReady extends FormBase {
    *
    * @var string
    */
-   protected $sitePath;
+  protected $sitePath;
 
   /**
    * Constructs a new UpdateReady object.
diff --git a/core/modules/update/src/UpdateSettingsForm.php b/core/modules/update/src/UpdateSettingsForm.php
index 1565f661e52a9ffe17b18869a08bae02251cb33d..d830de57f4536db6c8676ab16f0a99a03c243706 100644
--- a/core/modules/update/src/UpdateSettingsForm.php
+++ b/core/modules/update/src/UpdateSettingsForm.php
@@ -137,7 +137,7 @@ public function validateForm(array &$form, FormStateInterface $form_state) {
    */
   public function submitForm(array &$form, FormStateInterface $form_state) {
     $config = $this->config('update.settings');
-     // See if the update_check_disabled setting is being changed, and if so,
+    // See if the update_check_disabled setting is being changed, and if so,
     // invalidate all update status data.
     if ($form_state->getValue('update_check_disabled') != $config->get('check.disabled_extensions')) {
       update_storage_clear();
diff --git a/core/modules/update/update.module b/core/modules/update/update.module
index 349f6944516a9a3daff2449a415f9ddf3a3db251..f45b5893ea986562f05d1c098514b3336830266e 100644
--- a/core/modules/update/update.module
+++ b/core/modules/update/update.module
@@ -393,7 +393,7 @@ function update_refresh() {
  * @see \Drupal\update\UpdateProcessor::fetchData()
  */
 function update_fetch_data() {
- \Drupal::service('update.processor')->fetchData();
+  \Drupal::service('update.processor')->fetchData();
 }
 
 /**
diff --git a/core/modules/user/src/Plugin/migrate/process/d6/UserUpdate7002.php b/core/modules/user/src/Plugin/migrate/process/d6/UserUpdate7002.php
index 2f95a755808138b35f16974f9eadbe195b9ce35d..0efae5d6b3d5f71ae34601d81837fc96507c4847 100644
--- a/core/modules/user/src/Plugin/migrate/process/d6/UserUpdate7002.php
+++ b/core/modules/user/src/Plugin/migrate/process/d6/UserUpdate7002.php
@@ -25,11 +25,11 @@ class UserUpdate7002 extends ProcessPluginBase implements ContainerFactoryPlugin
    */
   protected static $timezones;
 
- /**
-  * Contains the system.theme configuration object.
-  *
-  * @var \Drupal\Core\Config\Config
-  */
+  /**
+   * Contains the system.theme configuration object.
+   *
+   * @var \Drupal\Core\Config\Config
+   */
   protected $dateConfig;
 
   /**
diff --git a/core/modules/user/src/Plugin/views/field/Permissions.php b/core/modules/user/src/Plugin/views/field/Permissions.php
index 42c78d2a6d4f1c8b607e5979e9504c64c57e428d..bd5c11d5d6c20da867134c0d411f6a09016a6d78 100644
--- a/core/modules/user/src/Plugin/views/field/Permissions.php
+++ b/core/modules/user/src/Plugin/views/field/Permissions.php
@@ -112,16 +112,4 @@ function render_item($count, $item) {
     return $item['permission'];
   }
 
-  /*
-  protected function documentSelfTokens(&$tokens) {
-    $tokens['[' . $this->options['id'] . '-role' . ']'] = $this->t('The name of the role.');
-    $tokens['[' . $this->options['id'] . '-rid' . ']'] = $this->t('The role ID of the role.');
-  }
-
-  protected function addSelfTokens(&$tokens, $item) {
-    $tokens['[' . $this->options['id'] . '-role' . ']'] = $item['role'];
-    $tokens['[' . $this->options['id'] . '-rid' . ']'] = $item['rid'];
-  }
-  */
-
 }
diff --git a/core/modules/user/src/Plugin/views/filter/Name.php b/core/modules/user/src/Plugin/views/filter/Name.php
index 5f63cb309bb3788d129c7f42c7b24bf718b269ef..e241e876361cc66180883fbf9b3e54c6b9285308 100644
--- a/core/modules/user/src/Plugin/views/filter/Name.php
+++ b/core/modules/user/src/Plugin/views/filter/Name.php
@@ -96,9 +96,9 @@ protected function valueSubmit($form, FormStateInterface $form_state) {
     // prevent array filter from removing our anonymous user.
   }
 
-/**
- * {@inheritdoc}
- */
+  /**
+   * {@inheritdoc}
+   */
   public function getValueOptions() {
     return $this->valueOptions;
   }
diff --git a/core/modules/user/src/Tests/RestRegisterUserTest.php b/core/modules/user/src/Tests/RestRegisterUserTest.php
index c10d0282810efdeebf117496c47ea9e3505469a6..62e6bbc687eed04556f8fff77a0cf388d9df22d7 100644
--- a/core/modules/user/src/Tests/RestRegisterUserTest.php
+++ b/core/modules/user/src/Tests/RestRegisterUserTest.php
@@ -124,25 +124,10 @@ protected function createSerializedUser($name, $include_password = TRUE) {
     global $base_url;
     // New user info to be serialized.
     $data = [
-      "_links" =>
-        [
-          "type" => ["href" => $base_url . "/rest/type/user/user"],
-        ],
-      "langcode" => [
-        [
-          "value" => "en",
-        ],
-      ],
-      "name" => [
-        [
-          "value" => $name,
-        ],
-      ],
-      "mail" => [
-        [
-          "value" => "$name@example.com",
-        ],
-      ],
+      "_links" => ["type" => ["href" => $base_url . "/rest/type/user/user"]],
+      "langcode" => [["value" => "en"]],
+      "name" => [["value" => $name]],
+      "mail" => [["value" => "$name@example.com"]],
     ];
     if ($include_password) {
       $data['pass']['value'] = 'SuperSecretPassword';
diff --git a/core/modules/user/src/Tests/UserBlocksTest.php b/core/modules/user/src/Tests/UserBlocksTest.php
index 40e63d8a4ce52bb60307cdce95ad4009f58efba7..f66007e2d8ad19ec2079236dff479a2653859383 100644
--- a/core/modules/user/src/Tests/UserBlocksTest.php
+++ b/core/modules/user/src/Tests/UserBlocksTest.php
@@ -34,9 +34,9 @@ protected function setUp() {
     $this->drupalLogout($this->adminUser);
   }
 
-   /**
-    * Tests that user login block is hidden from user/login.
-    */
+  /**
+   * Tests that user login block is hidden from user/login.
+   */
   function testUserLoginBlockVisibility() {
     // Array keyed list where key being the URL address and value being expected
     // visibility as boolean type.
@@ -51,7 +51,7 @@ function testUserLoginBlockVisibility() {
       $elements = $this->xpath('//div[contains(@class,"block-user-login-block") and @role="form"]');
       if ($expected_visibility) {
         $this->assertTrue(!empty($elements), 'User login block in path "' . $path . '" should be visible');
-     }
+      }
       else {
         $this->assertTrue(empty($elements), 'User login block in path "' . $path . '" should not be visible');
       }
diff --git a/core/modules/user/src/Tests/UserPasswordResetTest.php b/core/modules/user/src/Tests/UserPasswordResetTest.php
index 4f87f8a9272d3d6659dbf3ae7aaa4346d0ed47a9..c012e9f8d5000c5cadd1f8488920e5e3ca208dd3 100644
--- a/core/modules/user/src/Tests/UserPasswordResetTest.php
+++ b/core/modules/user/src/Tests/UserPasswordResetTest.php
@@ -88,7 +88,7 @@ function testUserPasswordReset() {
     $edit['name'] = $this->account->getUsername();
     $this->drupalPostForm(NULL, $edit, t('Submit'));
 
-     // Verify that the user was sent an email.
+    // Verify that the user was sent an email.
     $this->assertMail('to', $this->account->getEmail(), 'Password email sent to user.');
     $subject = t('Replacement login information for @username at @site', array('@username' => $this->account->getUsername(), '@site' => $this->config('system.site')->get('name')));
     $this->assertMail('subject', $subject, 'Password reset email subject is correct.');
@@ -332,6 +332,6 @@ function testResetImpersonation() {
     $this->assertNoText($user2->getUsername(), 'The invalid password reset page does not show the user name.');
     $this->assertUrl('user/password', array(), 'The user is redirected to the password reset request page.');
     $this->assertText('You have tried to use a one-time login link that has either been used or is no longer valid. Please request a new one using the form below.');
-   }
+  }
 
 }
diff --git a/core/modules/user/tests/fixtures/update/drupal-8.user-email-token-2587275.php b/core/modules/user/tests/fixtures/update/drupal-8.user-email-token-2587275.php
index 28dab8b108c1d6ec40788efe976da8049dfffc92..75ec703f8c76b48975cfff57618b87fa14e3d8fa 100644
--- a/core/modules/user/tests/fixtures/update/drupal-8.user-email-token-2587275.php
+++ b/core/modules/user/tests/fixtures/update/drupal-8.user-email-token-2587275.php
@@ -14,8 +14,8 @@
 // already.
 $connection->delete('config')->condition('name', 'user.mail')->execute();
 $connection->insert('config')
-->fields(array('collection', 'name', 'data'))
-->values(array(
+  ->fields(array('collection', 'name', 'data'))
+  ->values(array(
   'collection' => '',
   'name' => 'user.mail',
   'data' => "a:10:{s:14:\"cancel_confirm\";a:2:{s:4:\"body\";s:369:\"[user:name],\n\nA request to cancel your account has been made at [site:name].\n\nYou may now cancel your account on [site:url-brief] by clicking this link or copying and pasting it into your browser:\n\n[user:cancel-url]\n\nNOTE: The cancellation of your account is not reversible.\n\nThis link expires in one day and nothing will happen if it is not used.\n\n--  [site:name] team\";s:7:\"subject\";s:59:\"Account cancellation request for [user:name] at [site:name]\";}s:14:\"password_reset\";a:2:{s:4:\"body\";s:397:\"[user:name],\n\nA request to reset the password for your account has been made at [site:name].\n\nYou may now log in by clicking this link or copying and pasting it to your browser:\n\n[user:one-time-login-url]\n\nThis link can only be used once to log in and will lead you to a page where you can set your password. It expires after one day and nothing will happen if it's not used.\n\n--  [site:name] team\";s:7:\"subject\";s:60:\"Replacement login information for [user:name] at [site:name]\";}s:22:\"register_admin_created\";a:2:{s:4:\"body\";s:463:\"[user:name],\n\nA site administrator at [site:name] has created an account for you. You may now log in by clicking this link or copying and pasting it to your browser:\n\n[user:one-time-login-url]\n\nThis link can only be used once to log in and will lead you to a page where you can set your password.\n\nAfter setting your password, you will be able to log in at [site:login-url] in the future using:\n\nusername: [user:name]\npassword: Your password\n\n--  [site:name] team\";s:7:\"subject\";s:58:\"An administrator created an account for you at [site:name]\";}s:29:\"register_no_approval_required\";a:2:{s:4:\"body\";s:437:\"[user:name],\n\nThank you for registering at [site:name]. You may now log in by clicking this link or copying and pasting it to your browser:\n\n[user:one-time-login-url]\n\nThis link can only be used once to log in and will lead you to a page where you can set your password.\n\nAfter setting your password, you will be able to log in at [site:login-url] in the future using:\n\nusername: [user:name]\npassword: Your password\n\n--  [site:name] team\";s:7:\"subject\";s:46:\"Account details for [user:name] at [site:name]\";}s:25:\"register_pending_approval\";a:2:{s:4:\"body\";s:281:\"[user:name],\n\nThank you for registering at [site:name]. Your application for an account is currently pending approval. Once it has been approved, you will receive another email containing information about how to log in, set your password, and other details.\n\n\n--  [site:name] team\";s:7:\"subject\";s:71:\"Account details for [user:name] at [site:name] (pending admin approval)\";}s:31:\"register_pending_approval_admin\";a:2:{s:4:\"body\";s:56:\"[user:name] has applied for an account.\n\n[user:edit-url]\";s:7:\"subject\";s:71:\"Account details for [user:name] at [site:name] (pending admin approval)\";}s:16:\"status_activated\";a:2:{s:4:\"body\";s:446:\"[user:name],\n\nYour account at [site:name] has been activated.\n\nYou may now log in by clicking this link or copying and pasting it into your browser:\n\n[user:one-time-login-url]\n\nThis link can only be used once to log in and will lead you to a page where you can set your password.\n\nAfter setting your password, you will be able to log in at [site:login-url] in the future using:\n\nusername: [user:name]\npassword: Your password\n\n--  [site:name] team\";s:7:\"subject\";s:57:\"Account details for [user:name] at [site:name] (approved)\";}s:14:\"status_blocked\";a:2:{s:4:\"body\";s:89:\"[user:name],\n\nYour account on [site:account-name] has been blocked.\n\n--  [site:name] team\";s:7:\"subject\";s:56:\"Account details for [user:name] at [site:name] (blocked)\";}s:15:\"status_canceled\";a:2:{s:4:\"body\";s:82:\"[user:name],\n\nYour account on [site:name] has been canceled.\n\n--  [site:name] team\";s:7:\"subject\";s:57:\"Account details for [user:name] at [site:name] (canceled)\";}s:8:\"langcode\";s:2:\"en\";}"
diff --git a/core/modules/user/tests/src/Unit/PermissionHandlerTest.php b/core/modules/user/tests/src/Unit/PermissionHandlerTest.php
index 593d8c4f1aa43ca63c917d159d57a3e107e0908f..b0b91da89f153cae26ea208450be5e21cd2ce116 100644
--- a/core/modules/user/tests/src/Unit/PermissionHandlerTest.php
+++ b/core/modules/user/tests/src/Unit/PermissionHandlerTest.php
@@ -105,25 +105,25 @@ public function testBuildPermissionsYaml() {
 
     $url = vfsStream::url('modules');
     mkdir($url . '/module_a');
-    file_put_contents($url . '/module_a/module_a.permissions.yml',
-"access_module_a: single_description"
-    );
+    file_put_contents($url . '/module_a/module_a.permissions.yml', "access_module_a: single_description");
     mkdir($url . '/module_b');
-    file_put_contents($url . '/module_b/module_b.permissions.yml',
-"'access module b':
+    file_put_contents($url . '/module_b/module_b.permissions.yml', <<<EOF
+'access module b':
   title: 'Access B'
   description: 'bla bla'
 'access module a via module b':
   title: 'Access A via B'
   provider: 'module_a'
-");
+EOF
+    );
     mkdir($url . '/module_c');
-    file_put_contents($url . '/module_c/module_c.permissions.yml',
-"'access_module_c':
+    file_put_contents($url . '/module_c/module_c.permissions.yml', <<<EOF
+'access_module_c':
   title: 'Access C'
   description: 'bla bla'
   'restrict access': TRUE
-");
+EOF
+    );
     $modules = array('module_a', 'module_b', 'module_c');
     $extensions = array(
       'module_a' => $this->mockModuleExtension('module_a', 'Module a'),
@@ -187,9 +187,10 @@ public function testBuildPermissionsSortPerModule() {
 
     $url = vfsStream::url('modules');
     mkdir($url . '/module_a');
-    file_put_contents($url . '/module_a/module_a.permissions.yml',
-"access_module_a2: single_description2
-access_module_a1: single_description1"
+    file_put_contents($url . '/module_a/module_a.permissions.yml', <<<EOF
+access_module_a2: single_description2
+access_module_a1: single_description1
+EOF
     );
     mkdir($url . '/module_b');
     file_put_contents($url . '/module_b/module_b.permissions.yml',
@@ -234,21 +235,24 @@ public function testBuildPermissionsYamlCallback() {
 
     $url = vfsStream::url('modules');
     mkdir($url . '/module_a');
-    file_put_contents($url . '/module_a/module_a.permissions.yml',
-"permission_callbacks:
+    file_put_contents($url . '/module_a/module_a.permissions.yml', <<<EOF
+permission_callbacks:
   - 'Drupal\\user\\Tests\\TestPermissionCallbacks::singleDescription'
-");
+EOF
+    );
     mkdir($url . '/module_b');
-    file_put_contents($url . '/module_b/module_b.permissions.yml',
-"permission_callbacks:
+    file_put_contents($url . '/module_b/module_b.permissions.yml', <<<EOF
+permission_callbacks:
   - 'Drupal\\user\\Tests\\TestPermissionCallbacks::titleDescription'
   - 'Drupal\\user\\Tests\\TestPermissionCallbacks::titleProvider'
-");
+EOF
+    );
     mkdir($url . '/module_c');
-    file_put_contents($url . '/module_c/module_c.permissions.yml',
-"permission_callbacks:
+    file_put_contents($url . '/module_c/module_c.permissions.yml', <<<EOF
+permission_callbacks:
   - 'Drupal\\user\\Tests\\TestPermissionCallbacks::titleDescriptionRestrictAccess'
-");
+EOF
+    );
 
     $modules = array('module_a', 'module_b', 'module_c');
     $extensions = array(
@@ -309,13 +313,14 @@ public function testPermissionsYamlStaticAndCallback() {
 
     $url = vfsStream::url('modules');
     mkdir($url . '/module_a');
-    file_put_contents($url . '/module_a/module_a.permissions.yml',
-"'access module a':
+    file_put_contents($url . '/module_a/module_a.permissions.yml', <<<EOF
+'access module a':
   title: 'Access A'
   description: 'bla bla'
 permission_callbacks:
   - 'Drupal\\user\\Tests\\TestPermissionCallbacks::titleDescription'
-");
+EOF
+    );
 
     $modules = array('module_a');
     $extensions = array(
diff --git a/core/modules/user/tests/src/Unit/Plugin/Core/Entity/UserTest.php b/core/modules/user/tests/src/Unit/Plugin/Core/Entity/UserTest.php
index f3a542433e226219259a49c5dc11c33190151ba5..86ce8e9ac71871edf8faa84a1d8fa4b4d460058b 100644
--- a/core/modules/user/tests/src/Unit/Plugin/Core/Entity/UserTest.php
+++ b/core/modules/user/tests/src/Unit/Plugin/Core/Entity/UserTest.php
@@ -5,7 +5,7 @@
 use Drupal\Tests\Core\Session\UserSessionTest;
 use Drupal\user\RoleInterface;
 
-  /**
+/**
  * @coversDefaultClass \Drupal\user\Entity\User
  * @group user
  */
diff --git a/core/modules/user/user.module b/core/modules/user/user.module
index c530547387c3d3758d0ad2c90a219d215ec2ef75..1e9f539e0c423794a8afbe602f3c0d9b02484452 100644
--- a/core/modules/user/user.module
+++ b/core/modules/user/user.module
@@ -1334,7 +1334,7 @@ function user_toolbar() {
     $links_cache_contexts[] = 'user';
   }
   else {
-     $links = array(
+    $links = array(
       'login' => array(
         'title' => t('Log in'),
         'url' => Url::fromRoute('user.page'),
diff --git a/core/modules/views/src/Plugin/views/area/Entity.php b/core/modules/views/src/Plugin/views/area/Entity.php
index b1f5a1b18bbbc2f806371b047c497bf51c34dbe7..30c24ecb3a9e2191476511865a9ebcb587ae1969 100644
--- a/core/modules/views/src/Plugin/views/area/Entity.php
+++ b/core/modules/views/src/Plugin/views/area/Entity.php
@@ -115,7 +115,7 @@ public function buildOptionsForm(&$form, FormStateInterface $form_state) {
         $target = $target_entity->id();
       }
     }
-      $form['target'] = [
+    $form['target'] = [
       '#title' => $this->t('@entity_type_label ID', ['@entity_type_label' => $label]),
       '#type' => 'textfield',
       '#default_value' => $target,
diff --git a/core/modules/views/src/Plugin/views/area/View.php b/core/modules/views/src/Plugin/views/area/View.php
index a624423a9f8a10a6c0224611f7cdf46fe8afe906..12f417cf279d820f8334b0a14f2a877ed231a9b7 100644
--- a/core/modules/views/src/Plugin/views/area/View.php
+++ b/core/modules/views/src/Plugin/views/area/View.php
@@ -28,37 +28,37 @@ class View extends AreaPluginBase {
    *
    * @var \Drupal\Core\Entity\EntityStorageInterface
    */
-   protected $viewStorage;
-
-   /**
-    * Constructs a View object.
-    *
-    * @param array $configuration
-    *   A configuration array containing information about the plugin instance.
-    * @param string $plugin_id
-    *   The plugin_id for the plugin instance.
-    * @param mixed $plugin_definition
-    *   The plugin implementation definition.
-    * @param \Drupal\Core\Entity\EntityStorageInterface $view_storage
-    *   The view storage.
-    */
-   public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityStorageInterface $view_storage) {
-     parent::__construct($configuration, $plugin_id, $plugin_definition);
-
-     $this->viewStorage = $view_storage;
-   }
-
-   /**
-    * {@inheritdoc}
-    */
-   public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
-       return new static(
-           $configuration,
-           $plugin_id,
-           $plugin_definition,
-       $container->get('entity.manager')->getStorage('view')
-       );
-   }
+  protected $viewStorage;
+
+  /**
+   * Constructs a View object.
+   *
+   * @param array $configuration
+   *   A configuration array containing information about the plugin instance.
+   * @param string $plugin_id
+   *   The plugin_id for the plugin instance.
+   * @param mixed $plugin_definition
+   *   The plugin implementation definition.
+   * @param \Drupal\Core\Entity\EntityStorageInterface $view_storage
+   *   The view storage.
+   */
+  public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityStorageInterface $view_storage) {
+    parent::__construct($configuration, $plugin_id, $plugin_definition);
+
+    $this->viewStorage = $view_storage;
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
+    return new static(
+      $configuration,
+      $plugin_id,
+      $plugin_definition,
+      $container->get('entity.manager')->getStorage('view')
+    );
+  }
 
   /**
    * {@inheritdoc}
diff --git a/core/modules/views/src/Plugin/views/display/Block.php b/core/modules/views/src/Plugin/views/display/Block.php
index fe37d919f65f84648a82d94b38154446fd0a2d06..3e35d7e0309299594f5d9e39b81da252215b3676 100644
--- a/core/modules/views/src/Plugin/views/display/Block.php
+++ b/core/modules/views/src/Plugin/views/display/Block.php
@@ -346,11 +346,11 @@ public function preBlockBuild(ViewsBlock $block) {
    * Block views use exposed widgets only if AJAX is set.
    */
   public function usesExposed() {
-      if ($this->ajaxEnabled()) {
-        return parent::usesExposed();
-      }
-      return FALSE;
+    if ($this->ajaxEnabled()) {
+      return parent::usesExposed();
     }
+    return FALSE;
+  }
 
   /**
    * {@inheritdoc}
diff --git a/core/modules/views/src/Plugin/views/display/DisplayPluginBase.php b/core/modules/views/src/Plugin/views/display/DisplayPluginBase.php
index 102718d4537398d65950d9f82625d24628663804..37b6a4cc0222f3578f433f49afe3eb9f5353ea2e 100644
--- a/core/modules/views/src/Plugin/views/display/DisplayPluginBase.php
+++ b/core/modules/views/src/Plugin/views/display/DisplayPluginBase.php
@@ -37,7 +37,7 @@ abstract class DisplayPluginBase extends PluginBase implements DisplayPluginInte
    *
    * @var \Drupal\views\Plugin\views\ViewsHandlerInterface[]
    */
-   public $handlers = [];
+  public $handlers = [];
 
   /**
    * An array of instantiated plugins used in this display.
@@ -1051,9 +1051,9 @@ public function getArgumentsTokens() {
       if (!isset($tokens["%$count"])) {
         $tokens["%$count"] = '';
       }
-       // Use strip tags as there should never be HTML in the path.
-       // However, we need to preserve special characters like " that
-       // were encoded by \Drupal\Component\Utility\Html::escape().
+      // Use strip tags as there should never be HTML in the path.
+      // However, we need to preserve special characters like " that
+      // were encoded by \Drupal\Component\Utility\Html::escape().
       $tokens["!$count"] = isset($this->view->args[$count - 1]) ? strip_tags(Html::decodeEntities($this->view->args[$count - 1])) : '';
     }
 
@@ -2236,7 +2236,7 @@ public function access(AccountInterface $account = NULL) {
     }
 
     $plugin = $this->getPlugin('access');
-      /** @var \Drupal\views\Plugin\views\access\AccessPluginBase $plugin */
+    /** @var \Drupal\views\Plugin\views\access\AccessPluginBase $plugin */
     if ($plugin) {
       return $plugin->access($account);
     }
diff --git a/core/modules/views/src/Plugin/views/filter/FilterPluginBase.php b/core/modules/views/src/Plugin/views/filter/FilterPluginBase.php
index e4189c5bdeee7075fdf6f9ac4dfad3598ad07846..5c2a8d8c0fb3c46b034f3ea6e86649ebfcc4296d 100644
--- a/core/modules/views/src/Plugin/views/filter/FilterPluginBase.php
+++ b/core/modules/views/src/Plugin/views/filter/FilterPluginBase.php
@@ -540,7 +540,7 @@ public function buildExposeForm(&$form, FormStateInterface $form_state) {
     );
 
     if (!empty($form['operator']['#type'])) {
-       // Increase the width of the left (operator) column.
+      // Increase the width of the left (operator) column.
       $form['operator']['#prefix'] = '<div class="views-group-box views-left-40">';
       $form['operator']['#suffix'] = '</div>';
       $form['value']['#prefix'] = '<div class="views-group-box views-right-60">';
@@ -1307,7 +1307,7 @@ public function convertExposedInput(&$input, $selected_group_id = NULL) {
    */
   public function groupMultipleExposedInput(&$input) {
     if (!empty($input[$this->options['group_info']['identifier']])) {
-    return array_filter($input[$this->options['group_info']['identifier']]);
+      return array_filter($input[$this->options['group_info']['identifier']]);
     }
     return array();
   }
@@ -1491,9 +1491,9 @@ public function query() {
    *
    * @return bool
    */
-   public function canGroup() {
-     return TRUE;
-   }
+  public function canGroup() {
+    return TRUE;
+  }
 
   /**
    * {@inheritdoc}
diff --git a/core/modules/views/src/Plugin/views/pager/Mini.php b/core/modules/views/src/Plugin/views/pager/Mini.php
index 640010df07d854446d1a72ffbfa58ad87b5b8a6e..5f1750ea3cf03fe4a537011cc3fcbdf02d1c241e 100644
--- a/core/modules/views/src/Plugin/views/pager/Mini.php
+++ b/core/modules/views/src/Plugin/views/pager/Mini.php
@@ -38,7 +38,7 @@ public function summaryTitle() {
     if (!empty($this->options['offset'])) {
       return $this->formatPlural($this->options['items_per_page'], 'Mini pager, @count item, skip @skip', 'Mini pager, @count items, skip @skip', array('@count' => $this->options['items_per_page'], '@skip' => $this->options['offset']));
     }
-      return $this->formatPlural($this->options['items_per_page'], 'Mini pager, @count item', 'Mini pager, @count items', array('@count' => $this->options['items_per_page']));
+    return $this->formatPlural($this->options['items_per_page'], 'Mini pager, @count item', 'Mini pager, @count items', array('@count' => $this->options['items_per_page']));
   }
 
   /**
diff --git a/core/modules/views/src/Plugin/views/pager/Some.php b/core/modules/views/src/Plugin/views/pager/Some.php
index 2205f9d32e1aa2d6f93b54a79743c79affdda8dc..ef7f65d84375e845813e430522687e6f20d291c1 100644
--- a/core/modules/views/src/Plugin/views/pager/Some.php
+++ b/core/modules/views/src/Plugin/views/pager/Some.php
@@ -22,7 +22,7 @@ public function summaryTitle() {
     if (!empty($this->options['offset'])) {
       return $this->formatPlural($this->options['items_per_page'], '@count item, skip @skip', '@count items, skip @skip', array('@count' => $this->options['items_per_page'], '@skip' => $this->options['offset']));
     }
-      return $this->formatPlural($this->options['items_per_page'], '@count item', '@count items', array('@count' => $this->options['items_per_page']));
+    return $this->formatPlural($this->options['items_per_page'], '@count item', '@count items', array('@count' => $this->options['items_per_page']));
   }
 
   protected function defineOptions() {
diff --git a/core/modules/views/src/Plugin/views/sort/SortPluginBase.php b/core/modules/views/src/Plugin/views/sort/SortPluginBase.php
index cd9555eb304760e4ff7f034947bbb51a8ff32d2d..97122b1507de5a3e62fb92185606954ce67fe9bc 100644
--- a/core/modules/views/src/Plugin/views/sort/SortPluginBase.php
+++ b/core/modules/views/src/Plugin/views/sort/SortPluginBase.php
@@ -64,11 +64,10 @@ public function adminSummary() {
       case 'asc':
       default:
         return $this->t('asc');
-        break;
+
       case 'DESC';
       case 'desc';
         return $this->t('desc');
-        break;
     }
   }
 
diff --git a/core/modules/views/src/Tests/Entity/FieldEntityTranslationTest.php b/core/modules/views/src/Tests/Entity/FieldEntityTranslationTest.php
index eed71930198eced29e476ff588937f8751d534ca..bd4e2ed1f787646c62133d24773f1584d4a0699f 100644
--- a/core/modules/views/src/Tests/Entity/FieldEntityTranslationTest.php
+++ b/core/modules/views/src/Tests/Entity/FieldEntityTranslationTest.php
@@ -69,8 +69,7 @@ public function testTranslationRows() {
     $translation->save();
 
     $this->drupalGet('test_entity_field_renderers/entity_translation');
-    $this->assertRows(
-    [
+    $this->assertRows([
       [
         'title' => 'example EN',
         'sticky' => 'Off',
@@ -82,82 +81,76 @@ public function testTranslationRows() {
     ]);
 
     $this->drupalGet('test_entity_field_renderers/entity_default');
-    $this->assertRows(
+    $this->assertRows([
       [
-        [
-          'title' => 'example EN',
-          'sticky' => 'Off',
-        ],
-        [
-          'title' => 'example EN',
-          'sticky' => 'Off',
-        ],
-      ]);
+        'title' => 'example EN',
+        'sticky' => 'Off',
+      ],
+      [
+        'title' => 'example EN',
+        'sticky' => 'Off',
+      ],
+    ]);
 
     $this->drupalGet('test_entity_field_renderers/site_default');
-    $this->assertRows(
+    $this->assertRows([
+      [
+        'title' => 'example EN',
+        'sticky' => 'Off',
+      ],
       [
-        [
-          'title' => 'example EN',
-          'sticky' => 'Off',
-        ],
-        [
-          'title' => 'example EN',
-          'sticky' => 'Off',
-        ],
-      ]);
+        'title' => 'example EN',
+        'sticky' => 'Off',
+      ],
+    ]);
 
     $this->drupalGet('test_entity_field_renderers/language_interface');
-    $this->assertRows(
+    $this->assertRows([
+      [
+        'title' => 'example EN',
+        'sticky' => 'Off',
+      ],
       [
-        [
-          'title' => 'example EN',
-          'sticky' => 'Off',
-        ],
-        [
-          'title' => 'example EN',
-          'sticky' => 'Off',
-        ],
-      ]);
+        'title' => 'example EN',
+        'sticky' => 'Off',
+      ],
+    ]);
 
     $this->drupalGet('test_entity_field_renderers/language_interface', ['language' => new Language(['id' => 'es'])]);
-    $this->assertRows(
+    $this->assertRows([
       [
-        [
-          'title' => 'example ES',
-          'sticky' => 'On',
-        ],
-        [
-          'title' => 'example ES',
-          'sticky' => 'On',
-        ],
-      ]);
+        'title' => 'example ES',
+        'sticky' => 'On',
+      ],
+      [
+        'title' => 'example ES',
+        'sticky' => 'On',
+      ],
+    ]);
 
     $this->drupalGet('test_entity_field_renderers/en');
-    $this->assertRows(
+    $this->assertRows([
+      [
+        'title' => 'example EN',
+        'sticky' => 'Off',
+      ],
       [
-        [
-          'title' => 'example EN',
-          'sticky' => 'Off',
-        ],
-        [
-          'title' => 'example EN',
-          'sticky' => 'Off',
-        ],
-      ]);
+        'title' => 'example EN',
+        'sticky' => 'Off',
+      ],
+    ]);
 
     $this->drupalGet('test_entity_field_renderers/es');
-    $this->assertRows(
+    $this->assertRows([
+      [
+        'title' => 'example ES',
+        'sticky' => 'On',
+      ],
       [
-        [
-          'title' => 'example ES',
-          'sticky' => 'On',
-        ],
-        [
-          'title' => 'example ES',
-          'sticky' => 'On',
-        ],
-      ]);
+        'title' => 'example ES',
+        'sticky' => 'On',
+      ],
+    ]);
   }
 
   /**
diff --git a/core/modules/views/tests/modules/views_test_data/src/Plugin/views/query/QueryTest.php b/core/modules/views/tests/modules/views_test_data/src/Plugin/views/query/QueryTest.php
index 449474a63aeb15a779d3e367535dcaf11930c343..c1d04cf0c101cf232013d3f6ba0af8ba2df0ca4c 100644
--- a/core/modules/views/tests/modules/views_test_data/src/Plugin/views/query/QueryTest.php
+++ b/core/modules/views/tests/modules/views_test_data/src/Plugin/views/query/QueryTest.php
@@ -90,7 +90,7 @@ public function build(ViewExecutable $view) {
     // @todo You could add a string representation of the query.
     $this->view->build_info['query'] = "";
     $this->view->build_info['count_query'] = "";
-}
+  }
 
   /**
    * {@inheritdoc}
diff --git a/core/modules/views/tests/src/Kernel/Handler/FilterNumericTest.php b/core/modules/views/tests/src/Kernel/Handler/FilterNumericTest.php
index c6f5af92211f06035cad1285baf8c03e501e7d48..c4c978a115bcc4a3ed88b9ca3af822a8c288a47c 100644
--- a/core/modules/views/tests/src/Kernel/Handler/FilterNumericTest.php
+++ b/core/modules/views/tests/src/Kernel/Handler/FilterNumericTest.php
@@ -127,7 +127,7 @@ public function testFilterNumericBetween() {
     $view->destroy();
     $view->setDisplay();
 
-      // Change the filtering
+    // Change the filtering
     $view->displayHandlers->get('default')->overrideOption('filters', array(
       'age' => array(
         'id' => 'age',
diff --git a/core/modules/views/tests/src/Kernel/Handler/FilterStringTest.php b/core/modules/views/tests/src/Kernel/Handler/FilterStringTest.php
index e8c49773df8a2d0193128b3266c4d3776d179a68..5dd47ecb3b30ca3848efd4941d1658c4b4e9d175 100644
--- a/core/modules/views/tests/src/Kernel/Handler/FilterStringTest.php
+++ b/core/modules/views/tests/src/Kernel/Handler/FilterStringTest.php
@@ -297,7 +297,7 @@ function testFilterStringWord() {
 
 
   function testFilterStringGroupedExposedWord() {
-      $filters = $this->getGroupedExposedFilters();
+    $filters = $this->getGroupedExposedFilters();
     $view = $this->getBasicPageView();
 
     // Filter: Name, Operator: contains, Value: ing
diff --git a/core/modules/views/tests/src/Kernel/Handler/SortDateTest.php b/core/modules/views/tests/src/Kernel/Handler/SortDateTest.php
index 8c454b7b5e2431878e14980d9c055c7dfc7df5a1..4a137541125777c16ce42ee1926ec69c2dcd26bd 100644
--- a/core/modules/views/tests/src/Kernel/Handler/SortDateTest.php
+++ b/core/modules/views/tests/src/Kernel/Handler/SortDateTest.php
@@ -24,61 +24,61 @@ protected function expectedResultSet($granularity, $reverse = TRUE) {
     $expected = array();
     if (!$reverse) {
       switch ($granularity) {
-          case 'second':
-            $expected = array(
-              array('name' => 'John'),
-              array('name' => 'Paul'),
-              array('name' => 'Meredith'),
-              array('name' => 'Ringo'),
-              array('name' => 'George'),
-            );
-            break;
-          case 'minute':
-            $expected = array(
-              array('name' => 'John'),
-              array('name' => 'Paul'),
-              array('name' => 'Ringo'),
-              array('name' => 'Meredith'),
-              array('name' => 'George'),
-            );
-            break;
-          case 'hour':
-            $expected = array(
-              array('name' => 'John'),
-              array('name' => 'Ringo'),
-              array('name' => 'Paul'),
-              array('name' => 'Meredith'),
-              array('name' => 'George'),
-            );
-            break;
-          case 'day':
-            $expected = array(
-              array('name' => 'John'),
-              array('name' => 'Ringo'),
-              array('name' => 'Paul'),
-              array('name' => 'Meredith'),
-              array('name' => 'George'),
-            );
-            break;
-          case 'month':
-            $expected = array(
-              array('name' => 'John'),
-              array('name' => 'George'),
-              array('name' => 'Ringo'),
-              array('name' => 'Paul'),
-              array('name' => 'Meredith'),
-            );
-            break;
-          case 'year':
-            $expected = array(
-              array('name' => 'John'),
-              array('name' => 'George'),
-              array('name' => 'Ringo'),
-              array('name' => 'Paul'),
-              array('name' => 'Meredith'),
-            );
-            break;
-        }
+        case 'second':
+          $expected = array(
+            array('name' => 'John'),
+            array('name' => 'Paul'),
+            array('name' => 'Meredith'),
+            array('name' => 'Ringo'),
+            array('name' => 'George'),
+          );
+          break;
+        case 'minute':
+          $expected = array(
+            array('name' => 'John'),
+            array('name' => 'Paul'),
+            array('name' => 'Ringo'),
+            array('name' => 'Meredith'),
+            array('name' => 'George'),
+          );
+          break;
+        case 'hour':
+          $expected = array(
+            array('name' => 'John'),
+            array('name' => 'Ringo'),
+            array('name' => 'Paul'),
+            array('name' => 'Meredith'),
+            array('name' => 'George'),
+          );
+          break;
+        case 'day':
+          $expected = array(
+            array('name' => 'John'),
+            array('name' => 'Ringo'),
+            array('name' => 'Paul'),
+            array('name' => 'Meredith'),
+            array('name' => 'George'),
+          );
+          break;
+        case 'month':
+          $expected = array(
+            array('name' => 'John'),
+            array('name' => 'George'),
+            array('name' => 'Ringo'),
+            array('name' => 'Paul'),
+            array('name' => 'Meredith'),
+          );
+          break;
+        case 'year':
+          $expected = array(
+            array('name' => 'John'),
+            array('name' => 'George'),
+            array('name' => 'Ringo'),
+            array('name' => 'Paul'),
+            array('name' => 'Meredith'),
+          );
+          break;
+      }
     }
     else {
       switch ($granularity) {
diff --git a/core/modules/views/tests/src/Kernel/ModuleTest.php b/core/modules/views/tests/src/Kernel/ModuleTest.php
index ddf3347f042f26c62f873d100276a9e89f9670e4..204433dc963cbcfd3ce403378c703677e4f1cd99 100644
--- a/core/modules/views/tests/src/Kernel/ModuleTest.php
+++ b/core/modules/views/tests/src/Kernel/ModuleTest.php
@@ -199,7 +199,7 @@ public function testLoadFunctions() {
     $expected_opt_groups = array();
     foreach ($all_views as $view) {
       foreach ($view->get('display') as $display) {
-          $expected_opt_groups[$view->id()][$view->id() . ':' . $display['id']] = (string) t('@view : @display', array('@view' => $view->id(), '@display' => $display['id']));
+        $expected_opt_groups[$view->id()][$view->id() . ':' . $display['id']] = (string) t('@view : @display', array('@view' => $view->id(), '@display' => $display['id']));
       }
     }
     $this->assertIdentical($expected_opt_groups, $this->castSafeStrings(Views::getViewsAsOptions(FALSE, 'all', NULL, TRUE)), 'Expected option array for an option group returned.');
diff --git a/core/modules/views/tests/src/Unit/EntityViewsDataTest.php b/core/modules/views/tests/src/Unit/EntityViewsDataTest.php
index 35e8613de1f8ee476e18219a4b6f170dde5f4e53..60ba8e577084471b94d72727d146f0dfad69a4ae 100644
--- a/core/modules/views/tests/src/Unit/EntityViewsDataTest.php
+++ b/core/modules/views/tests/src/Unit/EntityViewsDataTest.php
@@ -568,7 +568,7 @@ public function testDataTableFields() {
 
     $this->viewsData->setEntityType($entity_type);
 
-     // Setup the table mapping.
+    // Setup the table mapping.
     $table_mapping = $this->getMockBuilder(DefaultTableMapping::class)
       ->disableOriginalConstructor()
       ->getMock();
@@ -717,7 +717,7 @@ public function testRevisionTableFields() {
 
     $this->viewsData->setEntityType($entity_type);
 
-     // Setup the table mapping.
+    // Setup the table mapping.
     $table_mapping = $this->getMockBuilder(DefaultTableMapping::class)
       ->disableOriginalConstructor()
       ->getMock();
diff --git a/core/modules/views_ui/src/Tests/CustomBooleanTest.php b/core/modules/views_ui/src/Tests/CustomBooleanTest.php
index 828b5b906e89479bc274fe85a012dc2a236f5aef..ecde493b63f49f563fa3fed81e73c5d794855c10 100644
--- a/core/modules/views_ui/src/Tests/CustomBooleanTest.php
+++ b/core/modules/views_ui/src/Tests/CustomBooleanTest.php
@@ -115,7 +115,7 @@ public function testCustomOptionTemplate() {
       ->save();
     $this->assertEqual($this->config('system.theme')->get('default'), 'views_test_theme');
 
-   // Add the boolean field handler to the test view.
+    // Add the boolean field handler to the test view.
     $view = Views::getView('test_view');
     $view->setDisplay();
 
diff --git a/core/modules/views_ui/src/ViewUI.php b/core/modules/views_ui/src/ViewUI.php
index 6195c8c583fafd1537b56c9dd2536852bdef160b..cb222b0b44299d6ee59a28795cfe862ca60eb27f 100644
--- a/core/modules/views_ui/src/ViewUI.php
+++ b/core/modules/views_ui/src/ViewUI.php
@@ -1160,9 +1160,9 @@ public function uriRelationships() {
   /**
    * {@inheritdoc}
    */
-   public function referencedEntities() {
-     return $this->storage->referencedEntities();
-   }
+  public function referencedEntities() {
+    return $this->storage->referencedEntities();
+  }
 
   /**
    * {@inheritdoc}
diff --git a/core/phpcs.xml.dist b/core/phpcs.xml.dist
index 29468f754ce6ba4674b19a81ddee1696c8cad2d8..6ab291865093f8452468aa309c5f37e037f67ad7 100644
--- a/core/phpcs.xml.dist
+++ b/core/phpcs.xml.dist
@@ -89,6 +89,7 @@
   <rule ref="Drupal.WhiteSpace.ObjectOperatorIndent"/>
   <rule ref="Drupal.WhiteSpace.ObjectOperatorSpacing"/>
   <rule ref="Drupal.WhiteSpace.OperatorSpacing"/>
+  <rule ref="Drupal.WhiteSpace.ScopeIndent"/>
 
   <!-- Generic sniffs -->
   <rule ref="Generic.Files.LineEndings"/>
diff --git a/core/tests/Drupal/KernelTests/AssertConfigTrait.php b/core/tests/Drupal/KernelTests/AssertConfigTrait.php
index c2e770f0e68d738f5d2a40faa66f0cb925c1e9f4..eb1588f18e8302f96dfa1bd47acf3ee5931d3c59 100644
--- a/core/tests/Drupal/KernelTests/AssertConfigTrait.php
+++ b/core/tests/Drupal/KernelTests/AssertConfigTrait.php
@@ -83,7 +83,6 @@ protected function assertConfigDiff(Diff $result, $config_name, array $skipped_c
           break;
         default:
           throw new \Exception($config_name . ': ' . var_export($op, TRUE));
-          break;
       }
     }
   }
diff --git a/core/tests/Drupal/KernelTests/Core/Database/DatabaseTestBase.php b/core/tests/Drupal/KernelTests/Core/Database/DatabaseTestBase.php
index b38c5b649a71da9e264634bad0d6d1832475e656..f8c8c3dcaf7926b915b6f086a65d42dc073c5655 100644
--- a/core/tests/Drupal/KernelTests/Core/Database/DatabaseTestBase.php
+++ b/core/tests/Drupal/KernelTests/Core/Database/DatabaseTestBase.php
@@ -36,20 +36,20 @@ protected function setUp() {
    */
   function ensureSampleDataNull() {
     db_insert('test_null')
-    ->fields(array('name', 'age'))
-    ->values(array(
+      ->fields(array('name', 'age'))
+      ->values(array(
       'name' => 'Kermit',
       'age' => 25,
     ))
-    ->values(array(
+      ->values(array(
       'name' => 'Fozzie',
       'age' => NULL,
     ))
-    ->values(array(
+      ->values(array(
       'name' => 'Gonzo',
       'age' => 27,
     ))
-    ->execute();
+      ->execute();
   }
 
   /**
diff --git a/core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php b/core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php
index eb0fbf65656e945f338c1cecc8d5fc20e016ef89..8c79c5c634259953fe9e97d0c58315f4f5e8aabd 100644
--- a/core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Entity/EntityQueryTest.php
@@ -481,7 +481,7 @@ public function testCount() {
       ->exists("$field_name.color")
       ->count()
       ->execute();
-     $this->assertFalse($count);
+    $this->assertFalse($count);
   }
 
   /**
diff --git a/core/tests/Drupal/KernelTests/Core/Menu/MenuLinkTreeTest.php b/core/tests/Drupal/KernelTests/Core/Menu/MenuLinkTreeTest.php
index 0cdc303e9ad90d2d69a2daed89925314ca842336..1efb14bc02ba9413c2cc865c3602cf3d532720fc 100644
--- a/core/tests/Drupal/KernelTests/Core/Menu/MenuLinkTreeTest.php
+++ b/core/tests/Drupal/KernelTests/Core/Menu/MenuLinkTreeTest.php
@@ -84,16 +84,16 @@ public function testDeleteLinksInMenu() {
    * Tests creating links with an expected tree structure.
    */
   public function testCreateLinksInMenu() {
-     // This creates a tree with the following structure:
-     // - 1
-     // - 2
-     //   - 3
-     //     - 4
-     // - 5
-     //   - 7
-     // - 6
-     // - 8
-     // With link 6 being the only external link.
+    // This creates a tree with the following structure:
+    // - 1
+    // - 2
+    //   - 3
+    //     - 4
+    // - 5
+    //   - 7
+    // - 6
+    // - 8
+    // With link 6 being the only external link.
 
     $links = array(
       1 => MenuLinkMock::create(array('id' => 'test.example1', 'route_name' => 'example1', 'title' => 'foo', 'parent' => '')),
diff --git a/core/tests/Drupal/KernelTests/KernelTestBaseTest.php b/core/tests/Drupal/KernelTests/KernelTestBaseTest.php
index 30f05b272eded2ab24499a58e95b298b28ddcfbd..1605ad69ad7bd256574729ad6ed7b404054bebd5 100644
--- a/core/tests/Drupal/KernelTests/KernelTestBaseTest.php
+++ b/core/tests/Drupal/KernelTests/KernelTestBaseTest.php
@@ -226,7 +226,7 @@ protected function tearDown() {
         ':pattern' => 'sqlite_%',
       ))->fetchAllKeyed(0, 0);
 
-     $this->assertTrue(empty($result), 'All test tables have been removed.');
+      $this->assertTrue(empty($result), 'All test tables have been removed.');
     }
   }
 
diff --git a/core/tests/Drupal/Tests/BrowserTestBase.php b/core/tests/Drupal/Tests/BrowserTestBase.php
index c8df47c7261e781e7f6808382fcb89c4ce81b855..ea88906dc5abebda5a3bee160636bda1a592a9cc 100644
--- a/core/tests/Drupal/Tests/BrowserTestBase.php
+++ b/core/tests/Drupal/Tests/BrowserTestBase.php
@@ -385,7 +385,7 @@ protected function getDefaultDriverInstance() {
     }
 
     if (is_array($this->minkDefaultDriverArgs)) {
-       // Use ReflectionClass to instantiate class with received params.
+      // Use ReflectionClass to instantiate class with received params.
       $reflector = new \ReflectionClass($this->minkDefaultDriverClass);
       $driver = $reflector->newInstanceArgs($this->minkDefaultDriverArgs);
     }
diff --git a/core/tests/Drupal/Tests/Component/ProxyBuilder/ProxyBuilderTest.php b/core/tests/Drupal/Tests/Component/ProxyBuilder/ProxyBuilderTest.php
index 53a14f5aa8431a3f5e87f767586e5077acb92a3c..f81ca0da4029400fbd9732cc858c8dc17f98ce95 100644
--- a/core/tests/Drupal/Tests/Component/ProxyBuilder/ProxyBuilderTest.php
+++ b/core/tests/Drupal/Tests/Component/ProxyBuilder/ProxyBuilderTest.php
@@ -230,7 +230,7 @@ public function testMethod($parameter)
 
 EOS;
 
-$this->assertEquals($this->buildExpectedClass($class, $method_body), $result);
+    $this->assertEquals($this->buildExpectedClass($class, $method_body), $result);
   }
 
   /**
diff --git a/core/tests/Drupal/Tests/Component/Utility/SafeMarkupTest.php b/core/tests/Drupal/Tests/Component/Utility/SafeMarkupTest.php
index b1a36b9b8761c240700777dda4b294a405732168..cbf86d209d4d02049f3642dd068ffe416ba16fe2 100644
--- a/core/tests/Drupal/Tests/Component/Utility/SafeMarkupTest.php
+++ b/core/tests/Drupal/Tests/Component/Utility/SafeMarkupTest.php
@@ -173,7 +173,7 @@ function providerFormat() {
 
     return $tests;
   }
-    /**
+  /**
    * Custom error handler that saves the last error.
    *
    * We need this custom error handler because we cannot rely on the error to
diff --git a/core/tests/Drupal/Tests/Core/Asset/LibraryDiscoveryParserTest.php b/core/tests/Drupal/Tests/Core/Asset/LibraryDiscoveryParserTest.php
index b79f5b1403241f8df93f5ba0266041d6600a939f..43d17fab1a381ad44a885e5de1d70a85661af75f 100644
--- a/core/tests/Drupal/Tests/Core/Asset/LibraryDiscoveryParserTest.php
+++ b/core/tests/Drupal/Tests/Core/Asset/LibraryDiscoveryParserTest.php
@@ -329,7 +329,7 @@ public function testLibraryWithCssJsSetting() {
    * @covers ::buildByExtension
    */
   public function testLibraryWithDependencies() {
-     $this->moduleHandler->expects($this->atLeastOnce())
+    $this->moduleHandler->expects($this->atLeastOnce())
       ->method('moduleExists')
       ->with('dependencies')
       ->will($this->returnValue(TRUE));
diff --git a/core/tests/Drupal/Tests/Core/Cache/CacheableMetadataTest.php b/core/tests/Drupal/Tests/Core/Cache/CacheableMetadataTest.php
index da6e9947d8ad25ff8affcdf04ee7b4de365a97e9..5eecf1cd792107f36b6bafca1ea2ec13504314c6 100644
--- a/core/tests/Drupal/Tests/Core/Cache/CacheableMetadataTest.php
+++ b/core/tests/Drupal/Tests/Core/Cache/CacheableMetadataTest.php
@@ -121,14 +121,14 @@ public function testSetCacheMaxAge($data, $expect_exception) {
    * Data provider for testSetCacheMaxAge.
    */
   public function providerSetCacheMaxAge() {
-   return [
-     [0 , FALSE],
-     ['http', TRUE],
-     ['0', TRUE],
-     [new \stdClass(), TRUE],
-     [300, FALSE],
-     [[], TRUE],
-     [8.0, TRUE]
+    return [
+      [0 , FALSE],
+      ['http', TRUE],
+      ['0', TRUE],
+      [new \stdClass(), TRUE],
+      [300, FALSE],
+      [[], TRUE],
+      [8.0, TRUE]
    ];
   }
 
diff --git a/core/tests/Drupal/Tests/Core/Entity/Sql/SqlContentEntityStorageTest.php b/core/tests/Drupal/Tests/Core/Entity/Sql/SqlContentEntityStorageTest.php
index 02970d7256baafec1edda03332cf486b301c7ea7..56b4b007e90dcd224b9be1fad6117effd8fd9151 100644
--- a/core/tests/Drupal/Tests/Core/Entity/Sql/SqlContentEntityStorageTest.php
+++ b/core/tests/Drupal/Tests/Core/Entity/Sql/SqlContentEntityStorageTest.php
@@ -1314,16 +1314,16 @@ public function testCleanIds() {
 
     $this->fieldDefinitions = $this->mockFieldDefinitions(array('id'));
     $this->fieldDefinitions['id']->expects($this->any())
-    ->method('getType')
-    ->will($this->returnValue('integer'));
+      ->method('getType')
+      ->will($this->returnValue('integer'));
 
     $this->setUpEntityStorage();
 
     $this->entityType->expects($this->any())
-    ->method('getKey')
-    ->will($this->returnValueMap(array(
-      array('id', 'id'),
-    )));
+      ->method('getKey')
+      ->will($this->returnValueMap(
+        array(array('id', 'id'))
+      ));
 
     $method = new \ReflectionMethod($this->entityStorage, 'cleanIds');
     $method->setAccessible(TRUE);
diff --git a/core/tests/Drupal/Tests/Core/Form/FormStateDecoratorBaseTest.php b/core/tests/Drupal/Tests/Core/Form/FormStateDecoratorBaseTest.php
index 0f1c27bb341113b66eb32e645a5b0be120691876..67e7a86165f0f90deccafc7b3555f6b9d4b50923 100644
--- a/core/tests/Drupal/Tests/Core/Form/FormStateDecoratorBaseTest.php
+++ b/core/tests/Drupal/Tests/Core/Form/FormStateDecoratorBaseTest.php
@@ -271,7 +271,7 @@ public function testHasFileElement($has_file_element) {
    *
    * @dataProvider providerLimitValidationErrors
    *
-   * @param array{}|null $limit_validation_errors
+   * @param array[]|null $limit_validation_errors
    *   Any valid value for
    *   \Drupal\Core\Form\FormStateInterface::setLimitValidationErrors()'s
    *   $limit_validation_errors argument;
@@ -577,7 +577,7 @@ public function testSetStorage() {
     ];
 
     $this->decoratedFormState->setStorage($storage)
-    ->shouldBeCalled();
+      ->shouldBeCalled();
 
     $this->assertSame($this->formStateDecoratorBase, $this->formStateDecoratorBase->setStorage($storage));
   }
diff --git a/core/tests/Drupal/Tests/Core/Menu/LocalActionManagerTest.php b/core/tests/Drupal/Tests/Core/Menu/LocalActionManagerTest.php
index 21c8839232ff2ab7ef9b2f4eca1d8266fb3be15f..92ce48e338715630f4194e4d6ac297d20fea2c0b 100644
--- a/core/tests/Drupal/Tests/Core/Menu/LocalActionManagerTest.php
+++ b/core/tests/Drupal/Tests/Core/Menu/LocalActionManagerTest.php
@@ -162,9 +162,9 @@ public function testGetActionsForRoute($route_appears, array $plugin_definitions
         ->method('getTitle')
         ->will($this->returnValue($plugin_definition['title']));
       $this->controllerResolver->expects($this->any())
-      ->method('getArguments')
-      ->with($this->request, array($plugin, 'getTitle'))
-      ->will($this->returnValue(array()));
+        ->method('getArguments')
+        ->with($this->request, array($plugin, 'getTitle'))
+        ->will($this->returnValue(array()));
 
       $plugin->expects($this->any())
         ->method('getWeight')
diff --git a/core/tests/Drupal/Tests/Core/Menu/LocalTaskManagerTest.php b/core/tests/Drupal/Tests/Core/Menu/LocalTaskManagerTest.php
index 65fb4172c37378f588893b79459b1b3a552c3ad4..5fc65ad97bd6e63a066569fe8d2850b1e20c16e5 100644
--- a/core/tests/Drupal/Tests/Core/Menu/LocalTaskManagerTest.php
+++ b/core/tests/Drupal/Tests/Core/Menu/LocalTaskManagerTest.php
@@ -441,7 +441,7 @@ public function testGetTasksBuildWithCacheabilityMetadata() {
     // Ensure that all cacheability metadata is merged together.
     $this->assertEquals(['tag.example1', 'tag.example2'], $cacheability->getCacheTags());
     $this->assertEquals(['context.example1', 'context.example2', 'route', 'user.permissions'], $cacheability->getCacheContexts());
- }
+  }
 
   protected function setupFactoryAndLocalTaskPlugins(array $definitions, $active_plugin_id) {
     $map = [];
diff --git a/core/tests/Drupal/Tests/Core/Render/Element/MachineNameTest.php b/core/tests/Drupal/Tests/Core/Render/Element/MachineNameTest.php
index c7ef72e3c5fd73fd46f1e3429f346de718e6bf29..d5340cb262491aa6641521d4613e90761e5ff8bd 100644
--- a/core/tests/Drupal/Tests/Core/Render/Element/MachineNameTest.php
+++ b/core/tests/Drupal/Tests/Core/Render/Element/MachineNameTest.php
@@ -2,10 +2,10 @@
 
 namespace Drupal\Tests\Core\Render\Element;
 
-  use Drupal\Core\Form\FormState;
-  use Drupal\Core\Form\FormStateInterface;
-  use Drupal\Core\Language\LanguageInterface;
-  use Drupal\Core\Language\LanguageManagerInterface;
+use Drupal\Core\Form\FormState;
+use Drupal\Core\Form\FormStateInterface;
+use Drupal\Core\Language\LanguageInterface;
+use Drupal\Core\Language\LanguageManagerInterface;
 use Drupal\Core\Render\Element\MachineName;
 use Drupal\Tests\UnitTestCase;
 use Symfony\Component\DependencyInjection\ContainerInterface;
diff --git a/core/tests/Drupal/Tests/Core/Render/RendererBubblingTest.php b/core/tests/Drupal/Tests/Core/Render/RendererBubblingTest.php
index 36a9a354f925f2749cabeb2dc02dfd26ca897692..a3835e1a3a6717ca9a32230d607119299f61bf31 100644
--- a/core/tests/Drupal/Tests/Core/Render/RendererBubblingTest.php
+++ b/core/tests/Drupal/Tests/Core/Render/RendererBubblingTest.php
@@ -326,9 +326,9 @@ public function testConditionalCacheContextBubblingSelfHealing() {
           ],
           'grandgrandchild' => [
             '#access_callback' => function () use (&$current_user_role) {
-                // Only role C can access this subtree.
-                return $current_user_role === 'C';
-              },
+              // Only role C can access this subtree.
+              return $current_user_role === 'C';
+            },
             '#cache' => [
               'contexts' => ['bar'],
               'tags' => ['d'],
diff --git a/core/tests/Drupal/Tests/Core/Routing/RedirectDestinationTest.php b/core/tests/Drupal/Tests/Core/Routing/RedirectDestinationTest.php
index 3b4a975341ce627fb4e80dd96af94865c3ed6f70..fd99e99075322dd839ecdfb4039d4782490547dd 100644
--- a/core/tests/Drupal/Tests/Core/Routing/RedirectDestinationTest.php
+++ b/core/tests/Drupal/Tests/Core/Routing/RedirectDestinationTest.php
@@ -101,7 +101,7 @@ public function providerGet() {
     // A request with a destination query.
     $data[] = [$request, '/example'];
 
-      // A request without a destination query,
+    // A request without a destination query,
     $request = Request::create('/');
     $data[] = [$request, '/current-path'];
 
diff --git a/core/tests/Drupal/Tests/Core/Session/UserSessionTest.php b/core/tests/Drupal/Tests/Core/Session/UserSessionTest.php
index f83515c9613bbafa72ad270aa0f6ac5f2e411db2..52969e03eb36bf17ccde0ab408637b35b05a0ad0 100644
--- a/core/tests/Drupal/Tests/Core/Session/UserSessionTest.php
+++ b/core/tests/Drupal/Tests/Core/Session/UserSessionTest.php
@@ -5,9 +5,9 @@
 use Drupal\Core\DependencyInjection\ContainerBuilder;
 use Drupal\Core\Session\UserSession;
 use Drupal\Tests\UnitTestCase;
-  use Drupal\user\RoleInterface;
+use Drupal\user\RoleInterface;
 
-  /**
+/**
  * @coversDefaultClass \Drupal\Core\Session\UserSession
  * @group Session
  */
diff --git a/core/tests/Drupal/Tests/Core/Site/SettingsTest.php b/core/tests/Drupal/Tests/Core/Site/SettingsTest.php
index 2c987f3c3077e3cb4eb8712d259c8f3b234a504d..3cf50fc266e2c509ca8d2f2463e6b2530d256409 100644
--- a/core/tests/Drupal/Tests/Core/Site/SettingsTest.php
+++ b/core/tests/Drupal/Tests/Core/Site/SettingsTest.php
@@ -95,11 +95,11 @@ public function testGetHashSaltEmpty(array $config) {
    * @return array
    */
   public function providerTestGetHashSaltEmpty() {
-   return array(
-     array(array()),
-     array(array('hash_salt' => '')),
-     array(array('hash_salt' => NULL)),
-   );
+    return array(
+      array(array()),
+      array(array('hash_salt' => '')),
+      array(array('hash_salt' => NULL)),
+    );
   }
 
   /**
diff --git a/core/tests/Drupal/Tests/Core/StackMiddleware/ReverseProxyMiddlewareTest.php b/core/tests/Drupal/Tests/Core/StackMiddleware/ReverseProxyMiddlewareTest.php
index 9bbf2e17547afa68781ad3407a9153f3231d29ac..585c4b975b7ebcb10f21e53146208b50f378f9f4 100644
--- a/core/tests/Drupal/Tests/Core/StackMiddleware/ReverseProxyMiddlewareTest.php
+++ b/core/tests/Drupal/Tests/Core/StackMiddleware/ReverseProxyMiddlewareTest.php
@@ -49,9 +49,9 @@ public function testNoProxy() {
    * @dataProvider reverseProxyEnabledProvider
    */
   public function testReverseProxyEnabled($provided_settings) {
-      // Enable reverse proxy and add test values.
-      $settings = new Settings(array('reverse_proxy' => 1) + $provided_settings);
-      $this->trustedHeadersAreSet($settings);
+    // Enable reverse proxy and add test values.
+    $settings = new Settings(array('reverse_proxy' => 1) + $provided_settings);
+    $this->trustedHeadersAreSet($settings);
   }
 
   /**
diff --git a/core/tests/Drupal/Tests/Core/StringTranslation/TranslatableMarkupTest.php b/core/tests/Drupal/Tests/Core/StringTranslation/TranslatableMarkupTest.php
index 183f57086e6d8f7791bfb7a91b5d1686134ad0e6..3ed2b3de6073a471629c612d36abb35f55c999a1 100644
--- a/core/tests/Drupal/Tests/Core/StringTranslation/TranslatableMarkupTest.php
+++ b/core/tests/Drupal/Tests/Core/StringTranslation/TranslatableMarkupTest.php
@@ -68,8 +68,8 @@ public function testToString() {
       ->method('translateString')
       ->with($text)
       ->willReturnCallback(function () {
-      throw new \Exception('Yes you may.');
-    });
+        throw new \Exception('Yes you may.');
+      });
 
     // We set a custom error handler because of https://github.com/sebastianbergmann/phpunit/issues/487
     set_error_handler([$this, 'errorHandler']);
diff --git a/core/tests/Drupal/Tests/Core/UrlTest.php b/core/tests/Drupal/Tests/Core/UrlTest.php
index b562745c8b86af51a8ab1e2747a22f643a87c97e..5324c26405bc1ff1208749b22f70fe7a81b14723 100644
--- a/core/tests/Drupal/Tests/Core/UrlTest.php
+++ b/core/tests/Drupal/Tests/Core/UrlTest.php
@@ -154,7 +154,7 @@ public function testUrlFromRequest() {
     return $urls;
   }
 
-   /**
+  /**
    * This constraint checks whether a Request object has the right path.
    *
    * @param string $path
diff --git a/core/tests/Drupal/Tests/Core/Utility/UnroutedUrlAssemblerTest.php b/core/tests/Drupal/Tests/Core/Utility/UnroutedUrlAssemblerTest.php
index f0203d70ef60311de2157861db56c8ed8e135f06..b2d7700e0c5c5e9f3c509c26d7cbe20786b6f137 100644
--- a/core/tests/Drupal/Tests/Core/Utility/UnroutedUrlAssemblerTest.php
+++ b/core/tests/Drupal/Tests/Core/Utility/UnroutedUrlAssemblerTest.php
@@ -77,11 +77,11 @@ public function testAssembleWithLeadingSlash() {
    * @dataProvider providerTestAssembleWithExternalUrl
    */
   public function testAssembleWithExternalUrl($uri, array $options, $expected) {
-   $this->setupRequestStack(FALSE);
-   $this->assertEquals($expected, $this->unroutedUrlAssembler->assemble($uri, $options));
-   $generated_url = $this->unroutedUrlAssembler->assemble($uri, $options, TRUE);
-   $this->assertEquals($expected, $generated_url->getGeneratedUrl());
-   $this->assertInstanceOf('\Drupal\Core\Render\BubbleableMetadata', $generated_url);
+    $this->setupRequestStack(FALSE);
+    $this->assertEquals($expected, $this->unroutedUrlAssembler->assemble($uri, $options));
+    $generated_url = $this->unroutedUrlAssembler->assemble($uri, $options, TRUE);
+    $this->assertEquals($expected, $generated_url->getGeneratedUrl());
+    $this->assertInstanceOf('\Drupal\Core\Render\BubbleableMetadata', $generated_url);
   }
 
   /**