def create_tenants(self): """Create tenants""" for x in range(MAX_RESOURCES): tenant_id = vpn_utils.create_tenant( self.keystone_client, self.suffixes[x]) with LOCK: self.tenant_ids.append(tenant_id)
def create_tenant(self): """Creates tenant :param keystone_client: keystone_admin_client :param tenant_ids : append created tenant id into the list :return: """ with LOCK: for x in range(MAX_RESOURCES): self.tenant_ids.append((vpn_utils.create_tenant( self.keystone_client, self.tenant_names[x])).id)