function RdfaAttributesTest::testRel

Same name in other branches
  1. 8.9.x core/modules/rdf/tests/src/Kernel/RdfaAttributesTest.php \Drupal\Tests\rdf\Kernel\RdfaAttributesTest::testRel()

Tests attribute creation for mappings which use 'rel'.

File

core/modules/rdf/tests/src/Kernel/RdfaAttributesTest.php, line 104

Class

RdfaAttributesTest
Tests RDFa attribute generation from RDF mapping.

Namespace

Drupal\Tests\rdf\Kernel

Code

public function testRel() {
    $properties = [
        'sioc:has_creator',
        'dc:creator',
    ];
    $mapping = [
        'properties' => $properties,
        'mapping_type' => 'rel',
    ];
    $expected_attributes = [
        'rel' => $properties,
    ];
    $this->_testAttributes($expected_attributes, $mapping);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.