diff --git a/core/modules/field/src/Tests/String/UuidFormatterTest.php b/core/modules/field/src/Tests/String/UuidFormatterTest.php index 4d849cd..57d45b7 100644 --- a/core/modules/field/src/Tests/String/UuidFormatterTest.php +++ b/core/modules/field/src/Tests/String/UuidFormatterTest.php @@ -47,11 +47,11 @@ public function testUuidStringFormatter() { $uuid_field = $entity->get('uuid'); $render_array = $uuid_field->view([]); - $this->assertIdentical($render_array[0]['#markup'], $entity->uuid(), 'The rendered UUID matches the entity UUID.'); + $this->assertIdentical($render_array[0]['#context']['value'], $entity->uuid(), 'The rendered UUID matches the entity UUID.'); $render_array = $uuid_field->view(['settings' => ['link_to_entity' => TRUE]]); $this->assertIdentical($render_array[0]['#type'], 'link'); - $this->assertIdentical($render_array[0]['#title']['#markup'], $entity->uuid()); + $this->assertIdentical($render_array[0]['#title']['#context']['value'], $entity->uuid()); $this->assertIdentical($render_array[0]['#url']->toString(), $entity->url()); } diff --git a/core/modules/taxonomy/src/Plugin/views/field/TermName.php b/core/modules/taxonomy/src/Plugin/views/field/TermName.php index c2eba0f..45246d1 100644 --- a/core/modules/taxonomy/src/Plugin/views/field/TermName.php +++ b/core/modules/taxonomy/src/Plugin/views/field/TermName.php @@ -28,7 +28,8 @@ public function getItems(ResultRow $values) { foreach ($items as &$item) { // Replace spaces with hyphens. $name = $item['raw']->get('value')->getValue(); - $item['rendered']['#markup'] = str_replace(' ', '-', $name); + // @todo Add link support https://www.drupal.org/node/2567745 + $item['rendered']['#context']['value'] = str_replace(' ', '-', $name); } } return $items;