def tearDown(self):
     try:
         for snapshot in self.snapshot_list:
             common_functions.delete_volume_snapshot(self.cinder, snapshot)
         self.snapshot_list = []
         for volume in self.volume_list:
             common_functions.delete_volume(self.cinder, volume)
         self.volume_list = []
     finally:
         self.cinder.quotas.update(self.tenant_id, snapshots=self.quota)
Exemplo n.º 2
0
 def tearDown(self):
     try:
         for snapshot in self.snapshot_list:
             common_functions.delete_volume_snapshot(self.cinder, snapshot)
         self.snapshot_list = []
         for volume in self.volume_list:
             common_functions.delete_volume(self.cinder, volume)
         self.volume_list = []
     finally:
         self.cinder.quotas.update(self.project_id, snapshots=self.quota)
Exemplo n.º 3
0
 def tearDown(self):
     for inst in self.instances:
         common_functions.delete_instance(self.nova, inst)
     self.instances = []
     for fip in self.floating_ips:
         common_functions.delete_floating_ip(self.nova, fip)
     self.floating_ips = []
     for volume in self.volumes:
         common_functions.delete_volume(self.cinder, volume)
     self.volumes = []
     for flavor in self.flavors:
         common_functions.delete_flavor(self.nova, flavor.id)
     self.flavors = []
     for key in self.keys:
         common_functions.delete_keys(self.nova, key.name)
     self.keys = []
     self.nova.security_groups.delete(self.sec_group)
Exemplo n.º 4
0
 def tearDown(self):
     for inst in self.instances:
         common_functions.delete_instance(self.nova, inst)
     self.instances = []
     for fip in self.floating_ips:
         common_functions.delete_floating_ip(self.nova, fip)
     self.floating_ips = []
     for volume in self.volumes:
         common_functions.delete_volume(self.cinder, volume)
     self.volumes = []
     for flavor in self.flavors:
         common_functions.delete_flavor(self.nova, flavor.id)
     self.flavors = []
     for key in self.keys:
         common_functions.delete_keys(self.nova, key.name)
     self.keys = []
     self.nova.security_groups.delete(self.sec_group)
Exemplo n.º 5
0
 def volumes(cls, os_conn):
     """Volumes cleanUp"""
     volumes = []
     yield volumes
     for volume in volumes:
         common_functions.delete_volume(os_conn.cinder, volume)