You are here

public function ConditionTest::testInvalidOperator in Entity API 8

::covers __construct.

File

tests/src/Unit/QueryAccess/ConditionTest.php, line 17

Class

ConditionTest
@coversDefaultClass \Drupal\entity\QueryAccess\Condition @group entity

Namespace

Drupal\Tests\entity\Unit\QueryAccess

Code

public function testInvalidOperator() {
  $this
    ->expectException(\InvalidArgumentException::class);
  $this
    ->expectExceptionMessage('Unrecognized operator "INVALID".');
  new Condition('uid', '1', 'INVALID');
}