/**
* Test getting API usage.
*/
public void testGetApiUsage() throws Exception {
// Create selector.
InfoSelector selector = new InfoSelector();
selector.setServiceName("CampaignService");
selector.setMethodName("mutate");
selector.setOperator(Operator.ADD);
selector.setDateRange(new DateRange(TestUtils.firstDayOfMonth(), TestUtils.today()));
selector.setApiUsageType(ApiUsageType.UNIT_COUNT);
ApiUsageInfo apiUsageInfo = service.get(selector);
assertNull(apiUsageInfo.getApiUsageRecords());
assertNotNull(apiUsageInfo.getCost());