1 ##############################################################################
2 # Copyright (c) 2017 Huawei Technologies Co.,Ltd and others.
4 # All rights reserved. This program and the accompanying materials
5 # are made available under the terms of the Apache License, Version 2.0
6 # which accompanies this distribution, and is available at
7 # http://www.apache.org/licenses/LICENSE-2.0
8 ##############################################################################
12 from yardstick.benchmark.scenarios.lib.delete_volume import DeleteVolume
15 class DeleteVolumeTestCase(unittest.TestCase):
17 @mock.patch('yardstick.common.openstack_utils.get_cinder_client')
18 @mock.patch('yardstick.common.openstack_utils.delete_volume')
19 def test_delete_volume(self, mock_get_cinder_client, mock_delete_volume):
21 'volume_id': '123-123-123'
23 args = {"options": options}
24 obj = DeleteVolume(args, {})
26 mock_get_cinder_client.assert_called_once()
27 mock_delete_volume.assert_called_once()