You are here

public function EntityResourceTest::replaceRelationshipDataProvider in JSON:API 8.2

Provides data for the testPatchRelationship.

Return value

array The input data for the test function.

File

tests/src/Kernel/Controller/EntityResourceTest.php, line 628

Class

EntityResourceTest
@coversDefaultClass \Drupal\jsonapi\Controller\EntityResource @group jsonapi @group legacy

Namespace

Drupal\Tests\jsonapi\Kernel\Controller

Code

public function replaceRelationshipDataProvider() {
  return [
    // Replace relationships.
    [
      [
        new ResourceIdentifier('node--article', static::$nodeUuid[1]),
        new ResourceIdentifier('node--article', static::$nodeUuid[2]),
      ],
    ],
    // Remove relationships.
    [
      [],
    ],
  ];
}