$this->entities
[] =
$entity;
$entity->
enforceIsNew();
$entity->
save();
} /**
* Tests basic functionality.
*/
public function testConfigEntityQuery() { // Run a test without any condition.
$this->queryResults =
$this->entityStorage->
getQuery() ->
execute();
$this->
assertResults(['1', '2', '3', '4', '5', '6', '7'
]);
// No conditions, OR.
$this->queryResults =
$this->entityStorage->
getQuery('OR'
) ->
execute();
$this->
assertResults(['1', '2', '3', '4', '5', '6', '7'
]);
// Filter by ID with equality.
$this->queryResults =
$this->entityStorage->
getQuery() ->
condition('id', '3'
) ->
execute();