public void initAllCapacity() {
        initAllCapacity(false);
        initAllCapacity(true);
    }
@Test
    void testInitAllCapacity() {
        List<String> groupList = new ArrayList<>();
        groupList.add("testGroup");
        when(configInfoPersistService.getGroupIdList(eq(1), eq(500))).thenReturn(groupList);
        List<String> tenantList = new ArrayList<>();
        tenantList.add("testTenant");
        when(configInfoPersistService.getTenantIdList(eq(1), eq(500))).thenReturn(tenantList);
        
        GroupCapacity groupCapacity = new GroupCapacity();
        groupCapacity.setGroup("testGroup");
        groupCapacity.setUsage(300);
        when(groupCapacityPersistService.insertGroupCapacity(any())).thenReturn(true);
        when(groupCapacityPersistService.getGroupCapacity(eq("testGroup"))).thenReturn(groupCapacity);
        when(groupCapacityPersistService.updateQuota(eq("testGroup"), eq(500))).thenReturn(true);
        
        TenantCapacity tenantCapacity = new TenantCapacity();
        tenantCapacity.setTenant("testTenant");
        tenantCapacity.setUsage(300);
        when(tenantCapacityPersistService.insertTenantCapacity(any())).thenReturn(true);
        when(tenantCapacityPersistService.getTenantCapacity(eq("testTenant"))).thenReturn(tenantCapacity);
        when(tenantCapacityPersistService.updateQuota(eq("testTenant"), eq(500))).thenReturn(true);
        
        service.initAllCapacity();
        
        Mockito.verify(groupCapacityPersistService, times(1)).insertGroupCapacity(any());
        Mockito.verify(groupCapacityPersistService, times(1)).getGroupCapacity(eq("testGroup"));
        Mockito.verify(groupCapacityPersistService, times(1)).updateQuota(eq("testGroup"), eq(500));
        
        Mockito.verify(tenantCapacityPersistService, times(1)).insertTenantCapacity(any());
        Mockito.verify(tenantCapacityPersistService, times(1)).getTenantCapacity(eq("testTenant"));
        Mockito.verify(tenantCapacityPersistService, times(1)).updateQuota(eq("testTenant"), eq(500));
    }