use of com.axibase.tsd.api.model.message.MessageStatsQuery in project atsd-api-test by axibase.
the class MessageQueryStatsTest method testAggregateCount.
@Issue("2945")
@Test(enabled = false)
public void testAggregateCount() throws Exception {
MessageStatsQuery statsQuery = prepareSimpleMessageStatsQuery(MESSAGE_STATS_ENTITY);
statsQuery.setAggregate(new Aggregate(AggregationType.COUNT));
List<Series> messageStatsList = queryMessageStatsReturnSeries(statsQuery);
assertEquals("Response should contain only 1 series", 1, messageStatsList.size());
List<Sample> samples = messageStatsList.get(0).getData();
assertEquals("Response should contain only 1 sample", 1, samples.size());
assertEquals("Message count mismatch", new BigDecimal(DATES.size()), samples.get(0).getValue());
}
Aggregations