2 Documentation Checking Subnets deleted in OpenStack are deleted also in OpenDaylight
4 Library RequestsLibrary
5 Resource ../../../variables/Variables.robot
7 Suite Setup Start Suite
8 Suite Teardown Delete All Sessions
12 ${OSREST} /v2.0/subnets/${SUBNETID}
14 ... {"subnet":{"network_id":"${NETID}","ip_version":4,"cidr":"172.16.64.0/24","allocation_pools":[{"start":"172.16.64.20","end":"172.16.64.120"}]}}
19 [Documentation] Delete previously created subnet in OpenStack
20 [Tags] delete subnet openstack neutron
22 ${resp} delete request OSSession ${OSREST}
23 Should be Equal As Strings ${resp.status_code} 204
27 Check New subnet deleted
28 [Documentation] Check subnet deleted in OpenDaylight
29 [Tags] check subnet deleted opendaylight
30 ${resp} get request ODLSession ${NEUTRON_SUBNETS_API}
31 Should be Equal As Strings ${resp.status_code} 200
32 ${ODLResult} To Json ${resp.text}
34 ${resp} get request ODLSession ${NEUTRON_SUBNETS_API}/${SUBNETID}
35 Should be Equal As Strings ${resp.status_code} 404
40 [Arguments] ${subnetid}
41 ${resp} get request ODLSession ${NEUTRON_SUBNETS_API}/${subnetid}
42 Should be Equal As Strings ${resp.status_code} 200
45 Create Session OSSession ${NEUTRONURL} headers=${X-AUTH-NOCONTENT}
46 Create Session ODLSession http://${ODL_SYSTEM_IP}:${PORT} headers=${HEADERS} auth=${AUTH}
47 Check Subnet Exists ${SUBNETID}