PowerMax driver - test fixes for _sanity_port_group_check

Feedback from https://review.openstack.org/#/c/631810 where
test parameters were switched around.

Change-Id: I2f4852c985055afccdb82c806857d2f4a0975028
This commit is contained in:
Helen Walsh 2019-03-08 15:33:57 +00:00 committed by Sean McGinnis
parent 3e55f98aac
commit 64e60ba30e
1 changed files with 3 additions and 3 deletions

View File

@ -67,20 +67,20 @@ class PowerMaxMaskingTest(test.TestCase):
self.assertRaises(
exception.VolumeBackendAPIException,
self.driver.masking._sanity_port_group_check,
self.data.array, None)
None, self.data.array)
@mock.patch.object(rest.PowerMaxRest, 'get_portgroup', return_value=None)
def test_sanity_port_group_check_invalid_portgroup(self, mock_pg):
self.assertRaises(
exception.VolumeBackendAPIException,
self.driver.masking._sanity_port_group_check,
self.data.array, None)
None, self.data.array)
@mock.patch.object(rest.PowerMaxRest, 'get_portgroup',
return_value=tpd.PowerMaxData.portgroup)
def test_sanity_port_group_check(self, mock_pg):
self.driver.masking._sanity_port_group_check(
self.data.array, self.data.port_group_name_f)
self.data.port_group_name_f, self.data.array)
@mock.patch.object(masking.PowerMaxMasking,
'get_or_create_masking_view_and_map_lun')