public function LinkFieldRdfaTest::testAllFormattersInternal in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/rdf/src/Tests/Field/LinkFieldRdfaTest.php \Drupal\rdf\Tests\Field\LinkFieldRdfaTest::testAllFormattersInternal()
Tests all formatters with link to internal page.
File
- core/
modules/ rdf/ src/ Tests/ Field/ LinkFieldRdfaTest.php, line 63 - Contains \Drupal\rdf\Tests\Field\LinkFieldRdfaTest.
Class
- LinkFieldRdfaTest
- Tests the placement of RDFa in link field formatters.
Namespace
Drupal\rdf\Tests\FieldCode
public function testAllFormattersInternal() {
// Set up test values.
$this->testValue = 'admin';
$this->entity = entity_create('entity_test', array());
$this->entity->{$this->fieldName}->uri = 'internal:/admin';
// Set up the expected result.
// AssertFormatterRdfa looks for a full path.
$expected_rdf = array(
'value' => $this->uri . '/' . $this->testValue,
'type' => 'uri',
);
$this
->runTestAllFormatters($expected_rdf, 'internal');
}