Mercurial > hg > cmmr2012-drupal-site
diff core/modules/rdf/tests/src/Functional/EntityReferenceFieldAttributesTest.php @ 5:12f9dff5fda9 tip
Update to Drupal core 8.7.1
author | Chris Cannam |
---|---|
date | Thu, 09 May 2019 15:34:47 +0100 |
parents | c75dbcec494b |
children |
line wrap: on
line diff
--- a/core/modules/rdf/tests/src/Functional/EntityReferenceFieldAttributesTest.php Thu Feb 28 13:11:55 2019 +0000 +++ b/core/modules/rdf/tests/src/Functional/EntityReferenceFieldAttributesTest.php Thu May 09 15:34:47 2019 +0100 @@ -2,6 +2,7 @@ namespace Drupal\Tests\rdf\Functional; +use Drupal\Core\Url; use Drupal\Core\Field\FieldStorageDefinitionInterface; use Drupal\Tests\taxonomy\Functional\TaxonomyTestBase; @@ -86,8 +87,8 @@ // Create a term in each vocabulary. $term1 = $this->createTerm($this->vocabulary); $term2 = $this->createTerm($this->vocabulary); - $taxonomy_term_1_uri = $term1->url('canonical', ['absolute' => TRUE]); - $taxonomy_term_2_uri = $term2->url('canonical', ['absolute' => TRUE]); + $taxonomy_term_1_uri = $term1->toUrl('canonical', ['absolute' => TRUE])->toString(); + $taxonomy_term_2_uri = $term2->toUrl('canonical', ['absolute' => TRUE])->toString(); // Create the node. $node = $this->drupalCreateNode(['type' => 'article']); @@ -103,11 +104,11 @@ // Parse the teaser. $parser = new \EasyRdf_Parser_Rdfa(); $graph = new \EasyRdf_Graph(); - $base_uri = \Drupal::url('<front>', [], ['absolute' => TRUE]); + $base_uri = Url::fromRoute('<front>', [], ['absolute' => TRUE])->toString(); $parser->parse($graph, $html, 'rdfa', $base_uri); // Node relations to taxonomy terms. - $node_uri = $node->url('canonical', ['absolute' => TRUE]); + $node_uri = $node->toUrl('canonical', ['absolute' => TRUE])->toString(); $expected_value = [ 'type' => 'uri', 'value' => $taxonomy_term_1_uri,