public function FilterTest::testInvalidFilterPathDueToMissingPropertyName in JSON:API 8.2
@covers ::queryCondition
File
- tests/
src/ Kernel/ Query/ FilterTest.php, line 77
Class
- FilterTest
- @coversDefaultClass \Drupal\jsonapi\Query\Filter @group jsonapi @group jsonapi_query @group legacy
Namespace
Drupal\Tests\jsonapi\Kernel\QueryCode
public function testInvalidFilterPathDueToMissingPropertyName() {
$this
->setExpectedException(CacheableBadRequestHttpException::class, 'Invalid nested filtering. The field `colors`, given in the path `colors` is incomplete, it must end with one of the following specifiers: `value`, `format`, `processed`.');
$resource_type = new ResourceType('node', 'painting', NULL);
Filter::createFromQueryParameter([
'colors' => '',
], $resource_type, $this->fieldResolver);
}