rpc: fix initiator address verification

In function verify_iscsi_connection_rpc_methods fixed
initiator address verification. It was used addres for target. From now
it is used separate addres for initiator.

Change-Id: I46ee7ab758b24342b6a25553a62a517914e9b70e
Signed-off-by: Slawomir Mrozowicz <slawomirx.mrozowicz@intel.com>
Reviewed-on: https://review.gerrithub.io/405582
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com>
Tested-by: SPDK Automated Test System <sys_sgsw@intel.com>
This commit is contained in:
Slawomir Mrozowicz 2018-03-29 11:04:21 +02:00 committed by Daniel Verkamp
parent bc9423e229
commit 5f9ba5b837

View File

@ -23,6 +23,7 @@ initiator_tag = '1'
rpc_param = {
'target_ip': target_ip,
'initiator_ip': initiator_ip,
'port': port,
'initiator_name': initiator_name,
'netmask': netmask,
@ -112,8 +113,8 @@ def verify_iscsi_connection_rpc_methods(rpc_py):
"target node name vaule is {}, expected {}".format(jsonvalues[0]['target_node_name'], rpc_param['target_name']))
verify(jsonvalues[0]['id'] == 0, 1,
"device id value is {}, expected 0".format(jsonvalues[0]['id']))
verify(jsonvalues[0]['initiator_addr'] == rpc_param['target_ip'], 1,
"initiator address values is {}, expected {}".format(jsonvalues[0]['initiator_addr'], rpc_param['target_ip']))
verify(jsonvalues[0]['initiator_addr'] == rpc_param['initiator_ip'], 1,
"initiator address values is {}, expected {}".format(jsonvalues[0]['initiator_addr'], rpc_param['initiator_ip']))
verify(jsonvalues[0]['target_addr'] == rpc_param['target_ip'], 1,
"target address values is {}, expected {}".format(jsonvalues[0]['target_addr'], rpc_param['target_ip']))