[Return] ${l2gw_output}
Delete L2Gateway
- [Arguments] ${gw_name}
+ [Arguments] ${gw_name} ${check_for_null}=False
[Documentation] Keyword to delete the L2 Gateway ${gw_name} received in argument.
+ ... If ${check_for_null} is True return of 404 is treated as empty list. From Neon onwards,
+ ... an empty list is always returned as null, giving 404 on rest call.
${output}= Exec Command ${OS_CNTL_CONN_ID} ${L2GW_DELETE} ${gw_name}
Log ${output}
@{list_to_check}= Create List ${gw_name}
BuiltIn.Wait Until Keyword Succeeds 5s 1s Utils.Check For Elements Not At URI ${L2GW_LIST_REST_URL} ${list_to_check} session
+ ... check_for_null=${check_for_null}
Create Verify L2Gateway Connection
[Arguments] ${gw_name} ${net_name}
Utils.Check For Elements At URI ${L2GW_CONN_LIST_REST_URL} ${list_to_check} session
Delete L2Gateway Connection
- [Arguments] ${gw_name}
+ [Arguments] ${gw_name} ${check_for_null}=False
[Documentation] Delete the L2 Gateway connection existing for Gateway ${gw_name} received in argument (Using Neutron CLI).
+ ... If ${check_for_null} is True return of 404 is treated as empty list. From Neon onwards, an empty list is always
+ ... returned as null, giving 404 on rest call.
${l2gw_conn_id}= OpenStackOperations.Get L2gw Connection Id ${gw_name}
${output}= Exec Command ${OS_CNTL_CONN_ID} ${L2GW_CONN_DELETE} ${l2gw_conn_id}
Log ${output}
@{list_to_check}= Create List ${l2gw_conn_id}
BuiltIn.Wait Until Keyword Succeeds 5s 1s Utils.Check For Elements Not At URI ${L2GW_CONN_LIST_REST_URL} ${list_to_check} session
+ ... check_for_null=${check_for_null}
Update Port For Hwvtep
[Arguments] ${port_name}
TC99 Cleanup L2Gateway Connection Itm Tunnel Port Subnet And Network
L2GatewayOperations.Delete L2Gateway Connection ${L2GW_NAME1}
- L2GatewayOperations.Delete L2Gateway Connection ${L2GW_NAME2}
+ L2GatewayOperations.Delete L2Gateway Connection ${L2GW_NAME2} check_for_null=True
L2GatewayOperations.Delete L2Gateway ${L2GW_NAME1}
- L2GatewayOperations.Delete L2Gateway ${L2GW_NAME2}
+ L2GatewayOperations.Delete L2Gateway ${L2GW_NAME2} check_for_null=True
OpenStackOperations.Delete Vm Instance ${OVS_VM1_NAME}
OpenStackOperations.Delete Vm Instance ${OVS_VM2_NAME}
OpenStackOperations.Delete Port ${OVS_PORT_1}