@mock.patch.object(dothill_common.DotHillCommon, 'create_volume')
def test_create_volume(self, mock_create):
- self._test_with_mock(mock_create, 'create_volume', [None],
- {'metadata': None})
+ self._test_with_mock(mock_create, 'create_volume', [None])
@mock.patch.object(dothill_common.DotHillCommon,
'create_cloned_volume')
def test_create_cloned_volume(self, mock_create):
- self._test_with_mock(mock_create, 'create_cloned_volume', [None, None],
- {'metadata': None})
+ self._test_with_mock(mock_create, 'create_cloned_volume', [None, None])
@mock.patch.object(dothill_common.DotHillCommon,
'create_volume_from_snapshot')
def test_create_volume_from_snapshot(self, mock_create):
self._test_with_mock(mock_create, 'create_volume_from_snapshot',
- [None, None], None)
+ [None, None])
@mock.patch.object(dothill_common.DotHillCommon, 'delete_volume')
def test_delete_volume(self, mock_delete):
'id': volume_name,
'size': volume_size, })
try:
- metadata = self.client.create_volume(volume_name,
- volume_size,
- self.backend_name,
- self.backend_type)
- return metadata
+ self.client.create_volume(volume_name,
+ volume_size,
+ self.backend_name,
+ self.backend_type)
except exception.DotHillRequestError as ex:
LOG.exception(_LE("Creation of volume %s failed."), volume['id'])
raise exception.Invalid(ex)
self.client_login()
try:
self.client.copy_volume(orig_name, dest_name, 0, self.backend_name)
- return None
except exception.DotHillRequestError as ex:
LOG.exception(_LE("Cloning of volume %s failed."),
volume['source_volid'])
self.client_login()
try:
self.client.copy_volume(orig_name, dest_name, 0, self.backend_name)
- return None
except exception.DotHillRequestError as ex:
LOG.exception(_LE("Create volume failed from snapshot: %s"),
snapshot['id'])
self._check_flags()
def create_volume(self, volume):
- return {'metadata': self.common.create_volume(volume)}
+ self.common.create_volume(volume)
def create_volume_from_snapshot(self, volume, src_vref):
self.common.create_volume_from_snapshot(volume, src_vref)
def create_cloned_volume(self, volume, src_vref):
- return {'metadata': self.common.create_cloned_volume(volume, src_vref)}
+ self.common.create_cloned_volume(volume, src_vref)
def delete_volume(self, volume):
self.common.delete_volume(volume)
self._check_flags()
def create_volume(self, volume):
- return {'metadata': self.common.create_volume(volume)}
+ self.common.create_volume(volume)
def create_volume_from_snapshot(self, volume, src_vref):
self.common.create_volume_from_snapshot(volume, src_vref)
def create_cloned_volume(self, volume, src_vref):
- return {'metadata': self.common.create_cloned_volume(volume, src_vref)}
+ self.common.create_cloned_volume(volume, src_vref)
def delete_volume(self, volume):
self.common.delete_volume(volume)