#NEWLINE# @ mock . patch . object ( volumeops . ISCSIVolumeDriver , 'logout_storage_target' ) #NEWLINE# def test_disconnect_volumes( self , mock_logout_storage_target ) : #NEWLINE# #INDENT# block_device_info = get_fake_block_dev_info ( ) #NEWLINE# connection_info = get_fake_connection_info ( ) #NEWLINE# block_device_mapping = block_device_info [ 'block_device_mapping' ] #NEWLINE# block_device_mapping [ 0 ] [ 'connection_info' ] = connection_info #NEWLINE# self . _volume_driver . disconnect_volumes ( block_device_mapping ) #NEWLINE# mock_logout_storage_target . assert_called_once_with ( mock . sentinel . fake_iqn , 1 )