expected_status needs to be a String, otherwise it leads to:
InvalidExpectedStatus: 200
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
Change-Id: Ia95baf7b4bbf0869b466576c25f0527592a9c227
Verify_BGP_Speaker_Connection
[Documentation] Verifies peer's presence in bgp rib.
[Arguments] ${session} ${ip} ${connected}=${True}
- ${exp_status_code}= BuiltIn.Set_Variable_If ${connected} ${200} ${404}
+ ${exp_status_code}= BuiltIn.Set_Variable_If ${connected} 200 404
${url}= BuiltIn.Set_Variable
... ${REST_API}/bgp-rib:bgp-rib/rib=example-bgp-rib/peer=bgp:%2F%2F${ip}?content=nonconfig
${response}= RequestsLibrary.GET On Session ${session} ${url} expected_status=${exp_status_code}
[Arguments] ${session} ${peer_ip} ${connected}=${True}
# TODO: This keyword is not specific to prefix counting. Find a better place for it.
${peer_check_url} = BuiltIn.Set_Variable ${REST_API}/bgp-rib:bgp-rib/rib=example-bgp-rib/peer=bgp:%2F%2F
- ${exp_status_code} = BuiltIn.Set_Variable_If ${connected} ${200} ${404}
+ ${exp_status_code} = BuiltIn.Set_Variable_If ${connected} 200 404
${rsp} = RequestsLibrary.GET On Session ${session} ${peer_check_url}${peer_ip}?content=nonconfig expected_status=${exp_status_code}
BuiltIn.Log ${rsp.content}