$this->
assertResults([ ['user_id' => 1, 'id_count' => 1
],
['user_id' => 2, 'id_count' => 3
],
['user_id' => 3, 'id_count' => 2
],
]);
// Apply aggregation and a condition which matches.
$this->queryResult =
$this->entityStorage->
getAggregateQuery() ->
accessCheck(FALSE
) ->
aggregate('id', 'COUNT'
) ->
groupBy('id'
) ->
conditionAggregate('id', 'COUNT', 8
) ->
execute();
$this->
assertResults([]);
// Don't call aggregate to test the implicit aggregate call.
$this->queryResult =
$this->entityStorage->
getAggregateQuery() ->
accessCheck(FALSE
) ->
groupBy('id'
) ->
conditionAggregate('id', 'COUNT', 8
) ->
execute();
$this->
assertResults([]);