Remove return for rpc casts in rpc worker client
RPC casts never return anything, only RPC calls do, so remove the misleading return in the worker client. Change-Id: I82e2ead0b350be42f808f6cb6b9b57b786aeadcf
This commit is contained in:
parent
848d63b398
commit
8e5c35d897
@ -46,4 +46,4 @@ class WorkerClient(object):
|
||||
client = self._client.prepare(version=version)
|
||||
else:
|
||||
client = self._client
|
||||
return client.cast(ctxt, method, **kwargs)
|
||||
client.cast(ctxt, method, **kwargs)
|
||||
|
@ -58,14 +58,16 @@ class WorkerClientTest(common.HeatTestCase):
|
||||
msg = method, kwargs
|
||||
|
||||
# go with default version
|
||||
worker_client.cast(mock_cnxt, msg)
|
||||
return_value = worker_client.cast(mock_cnxt, msg)
|
||||
self.assertIsNone(return_value)
|
||||
mock_rpc_client.cast.assert_called_once_with(mock_cnxt,
|
||||
method,
|
||||
**kwargs)
|
||||
|
||||
# Check cast in given version
|
||||
version = '1.2'
|
||||
worker_client.cast(mock_cnxt, msg, version)
|
||||
return_value = worker_client.cast(mock_cnxt, msg, version)
|
||||
self.assertIsNone(return_value)
|
||||
mock_rpc_client.prepare.assert_called_once_with(version=version)
|
||||
mock_rpc_client.cast.assert_called_once_with(mock_cnxt,
|
||||
method,
|
||||
|
Loading…
Reference in New Issue
Block a user