public TenantCapacity getTenantCapacity(String tenantId) {
        TenantCapacityMapper tenantCapacityMapper = mapperManager.findMapper(dataSourceService.getDataSourceType(),
                TableConstant.TENANT_CAPACITY);
        String sql = tenantCapacityMapper.select(
                Arrays.asList("id", "quota", "`usage`", "`max_size`", "max_aggr_count", "max_aggr_size", "tenant_id"),
                Collections.singletonList("tenant_id"));
        List<TenantCapacity> list = jdbcTemplate.query(sql, new Object[] {tenantId}, TENANT_CAPACITY_ROW_MAPPER);
        if (list.isEmpty()) {
            return null;
        }
        return list.get(0);
    }
@Test
    void testGetTenantCapacity() {
        
        List<TenantCapacity> list = new ArrayList<>();
        TenantCapacity tenantCapacity = new TenantCapacity();
        tenantCapacity.setTenant("test");
        list.add(tenantCapacity);
        
        String tenantId = "testId";
        when(jdbcTemplate.query(anyString(), eq(new Object[] {tenantId}), any(RowMapper.class))).thenReturn(list);
        TenantCapacity ret = service.getTenantCapacity(tenantId);
        
        assertEquals(tenantCapacity.getTenant(), ret.getTenant());
    }