Merge "Change assertTrue(isinstance()) with optimal assert"
This commit is contained in:
commit
5e64248de8
|
@ -89,8 +89,8 @@ class RBDConnectorTestCase(test_connector.ConnectorTestCase):
|
|||
snapshot=None)
|
||||
|
||||
# Ensure expected object is returned correctly
|
||||
self.assertTrue(isinstance(device_info['path'],
|
||||
linuxrbd.RBDVolumeIOWrapper))
|
||||
self.assertIsInstance(device_info['path'],
|
||||
linuxrbd.RBDVolumeIOWrapper)
|
||||
|
||||
@mock.patch('os_brick.initiator.connectors.rbd.tempfile.mkstemp')
|
||||
def test_create_ceph_conf(self, mock_mkstemp):
|
||||
|
|
|
@ -59,8 +59,8 @@ class SheepdogConnectorTestCase(test_connector.ConnectorTestCase):
|
|||
device_info = sd_connector.connect_volume(self.connection_properties)
|
||||
|
||||
# Ensure expected object is returned correctly
|
||||
self.assertTrue(isinstance(device_info['path'],
|
||||
linuxsheepdog.SheepdogVolumeIOWrapper))
|
||||
self.assertIsInstance(device_info['path'],
|
||||
linuxsheepdog.SheepdogVolumeIOWrapper)
|
||||
|
||||
@mock.patch.object(linuxsheepdog.SheepdogVolumeIOWrapper, 'close')
|
||||
def test_disconnect_volume(self, volume_close):
|
||||
|
|
Loading…
Reference in New Issue