You are here

public function EntityLoadHelperTest::testCategorizeAttributesProperlyIdentifiesProperties in YAML Content 8

Test categorizeAttributes identifies properties as expected.

@covers ::categorizeAttributes @covers ::identifyAttributeType

@dataProvider attributeCategorizationProvider

File

tests/src/Unit/EntityLoadHelper/EntityLoadHelperTest.php, line 488

Class

EntityLoadHelperTest
Test functionality of the EntityLoadHelper class.

Namespace

Drupal\Tests\yaml_content\Unit\EntityLoadHelper

Code

public function testCategorizeAttributesProperlyIdentifiesProperties($entity_type, $content, $expected) {
  $this
    ->setUpCategorizeAttributesTests();

  // Execute the method.
  $actual = $this->loadHelper
    ->categorizeAttributes($entity_type, $content);
  $this
    ->assertArrayEquals($expected['property'], $actual['property']);
}