function FilterTest::parameterProvider

Data provider for testCreateFromQueryParameter.

File

core/modules/jsonapi/tests/src/Kernel/Query/FilterTest.php, line 327

Class

FilterTest
@coversDefaultClass \Drupal\jsonapi\Query\Filter[[api-linebreak]] @group jsonapi @group jsonapi_query

Namespace

Drupal\Tests\jsonapi\Kernel\Query

Code

public function parameterProvider() {
  return [
    'shorthand' => [
      [
        'uid' => [
          'value' => 1,
        ],
      ],
      [
        [
          'path' => 'uid',
          'value' => 1,
          'operator' => '=',
        ],
      ],
    ],
    'extreme shorthand' => [
      [
        'uid' => 1,
      ],
      [
        [
          'path' => 'uid',
          'value' => 1,
          'operator' => '=',
        ],
      ],
    ],
  ];
}

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