diff options
Diffstat (limited to 'framework/src/onos/tools/test/scenarios')
36 files changed, 0 insertions, 1712 deletions
diff --git a/framework/src/onos/tools/test/scenarios/archetypes.xml b/framework/src/onos/tools/test/scenarios/archetypes.xml deleted file mode 100644 index 5440b55f..00000000 --- a/framework/src/onos/tools/test/scenarios/archetypes.xml +++ /dev/null @@ -1,68 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="archetypes" description="ONOS archetypes test"> - <group name="Archetypes" cwd="${WORKSPACE}/tmp/test-app"> - <step name="Clean-Up" cwd="${WORKSPACE}/tmp" env="~" - exec="rm -r test-app"/> - - <step name="Create-App" cwd="${WORKSPACE}/tmp" requires="^" - exec="onos-create-app app org.test.app test-app 1.2.3 org.test.app -DinteractiveMode=false"/> - <step name="Build-App" requires="Create-App" exec="mvn clean install"/> - <step name="Install-App" requires="^" - exec="onos-app ${OCI} install! target/test-app-1.2.3.oar"/> - <step name="Verify-App" requires="^" - exec="onos-check-components ${OCI} org.test.app.AppComponent"/> - - <step name="Create-App-CLI-Overlay" requires="Install-App" - exec="onos-create-app cli org.test.app test-app 1.2.3 org.test.app -DinteractiveMode=false"/> - <step name="Build-App-With-CLI" requires="^" - exec="mvn clean install"/> - <step name="Reinstall-App-With-CLI" requires="^,~Verify-App" - exec="onos-app ${OCI} reinstall! target/test-app-1.2.3.oar"/> - <step name="Verify-CLI" requires="^" - exec="onos ${OCI} sample"/> - - <step name="Create-App-UI-Overlay" requires="Reinstall-App-With-CLI" - exec="onos-create-app ui org.test.app test-app 1.2.3 org.test.app -DinteractiveMode=false"/> - <step name="Build-App-With-UI" requires="^" - exec="mvn clean install"/> - <step name="Reinstall-App-With-UI" requires="^,~Verify-CLI" - exec="onos-app ${OCI} reinstall! target/test-app-1.2.3.oar"/> - <step name="Verify-UI" requires="^" - exec="onos-check-views ${OCI} id=sample"/> - - <step name="Create-App-UI-Table-Overlay" requires="Reinstall-App-With-UI" - exec="onos-create-app uitab org.test.app test-app 1.2.3 org.test.app -DinteractiveMode=false"/> - <step name="Build-App-With-UI-Table" requires="^" - exec="mvn clean install"/> - <step name="Reinstall-App-With-UI-Table" requires="^,~Verify-UI" - exec="onos-app ${OCI} reinstall! target/test-app-1.2.3.oar"/> - <step name="Verify-UI-Table" requires="^" - exec="onos-check-views ${OCI} id=sample"/> - - <step name="Create-App-UI-Topo-Overlay" requires="Reinstall-App-With-UI-Table" - exec="onos-create-app uitopo org.test.app test-app 1.2.3 org.test.app -DinteractiveMode=false"/> - <step name="Build-App-With-UI-Topo" requires="^" - exec="mvn clean install"/> - <step name="Reinstall-App-With-UI-Topo" requires="^,~Verify-UI-Table" - exec="onos-app ${OCI} reinstall! target/test-app-1.2.3.oar"/> - <step name="Verify-UI-Topo" requires="^" - exec="onos-check-views ${OCI} id=sample"/> - - <step name="Uninstall-App" requires="^" - exec="onos-app ${OCI} uninstall org.foo.app"/> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/bin/create-flow.py b/framework/src/onos/tools/test/scenarios/bin/create-flow.py deleted file mode 100755 index 4e9b452b..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/create-flow.py +++ /dev/null @@ -1,56 +0,0 @@ -#! /usr/bin/env python - -import requests - -from requests.auth import HTTPBasicAuth -import sys - - - -if len(sys.argv) != 6: - print "usage: create-flow onos-node name device in-port out-port" - sys.exit(1) - -node = sys.argv[1] -name = sys.argv[2] -device = sys.argv[3] -inPort = sys.argv[4] -outPort = sys.argv[5] - -flowJsonTemplate = \ - '{{' + \ - '"priority": 1,' + \ - '"isPermanent": true,' + \ - '"treatment": {{' + \ - '"instructions": [' + \ - '{{' + \ - '"type": "OUTPUT",' + \ - '"port": {}' + \ - '}}' + \ - ']' + \ - '}},' + \ - '"selector": {{' + \ - '"criteria": [' + \ - '{{' + \ - '"type": "IN_PORT",' + \ - '"port": {}' + \ - '}}' + \ - ']' + \ - '}}' + \ - '}}' - -flowJson = flowJsonTemplate.format(inPort, outPort) -intentRequest = requests.post('http://' + node + ':8181/onos/v1/flows/' + device, - auth=HTTPBasicAuth('onos', 'rocks'), - data=flowJson) - -if intentRequest.status_code != 201: - print intentRequest.text - sys.exit(1) - -location = intentRequest.headers["location"] -print "@stc " + name + "Location=" + location -sys.exit(0) - - - diff --git a/framework/src/onos/tools/test/scenarios/bin/create-intent.py b/framework/src/onos/tools/test/scenarios/bin/create-intent.py deleted file mode 100755 index 4e5d4f62..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/create-intent.py +++ /dev/null @@ -1,49 +0,0 @@ -#! /usr/bin/env python - -import requests - -from requests.auth import HTTPBasicAuth -import sys - - - -if len(sys.argv) != 7: - print "usage: create-intent onos-node name ingressDevice ingressPort egressDevice egressPort" - sys.exit(1) - -node = sys.argv[1] -name = sys.argv[2] -ingress = sys.argv[3] -ingressPort = sys.argv[4] -egress = sys.argv[5] -egressPort = sys.argv[6] - -intentJsonTemplate = \ - '{{' + \ - '"type": "PointToPointIntent",' + \ - '"appId": "org.onosproject.cli",' + \ - '"ingressPoint": {{' + \ - ' "device": "{}",' + \ - ' "port": "{}"' + \ - '}},' + \ - '"egressPoint": {{' + \ - ' "device": "{}",' + \ - ' "port": "{}"' + \ - '}}' + \ - '}}' - -intentJson = intentJsonTemplate.format(ingress, ingressPort, egress, egressPort) -intentRequest = requests.post('http://' + node + ':8181/onos/v1/intents/', - auth=HTTPBasicAuth('onos', 'rocks'), - data=intentJson) - -if intentRequest.status_code != 201: - print intentRequest.text - sys.exit(1) - -location = intentRequest.headers["location"] -print "@stc " + name + "Location=" + location -sys.exit(0) - - - diff --git a/framework/src/onos/tools/test/scenarios/bin/curl-with-retry b/framework/src/onos/tools/test/scenarios/bin/curl-with-retry deleted file mode 100755 index c9546aea..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/curl-with-retry +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/bash - -aux=/tmp/stc-$$.log -trap "rm -f $aux 2>/dev/null" EXIT - -url=$1 - - -echo curl-with-retry: $* - -set -x -for i in {1..3}; do - curl -f -uonos:rocks ${url} >$aux - if [ $? = 0 ]; then - cat $aux - exit 0 - fi - sleep 1 -done - -cat $aux -exit 1 - diff --git a/framework/src/onos/tools/test/scenarios/bin/find-device.py b/framework/src/onos/tools/test/scenarios/bin/find-device.py deleted file mode 100755 index 430e18ad..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/find-device.py +++ /dev/null @@ -1,39 +0,0 @@ -#! /usr/bin/env python - -import requests -import sys -import urllib - -from requests.auth import HTTPBasicAuth - -if len(sys.argv) != 4: - print "usage: find-device onos-node name device-id" - sys.exit(1) - -node = sys.argv[1] -name = sys.argv[2] -id = sys.argv[3] - -deviceRequest = requests.get('http://' + node + ':8181/onos/v1/devices/' + - urllib.quote_plus(id), - auth=HTTPBasicAuth('onos', 'rocks')) - -if deviceRequest.status_code != 200: - print deviceRequest.text - sys.exit(1) - -deviceJson = deviceRequest.json() - -print "@stc " + name + "Id=" + deviceJson["id"] -print "@stc " + name + "Type=" + deviceJson["type"] -print "@stc " + name + "Available=" + str(deviceJson["available"]) -channelId = deviceJson["annotations"]["channelId"] -channelIdWords = channelId.split(':') -print "@stc " + name + "IpAddress=" + channelIdWords[0] - -sys.exit(0) - - - - - diff --git a/framework/src/onos/tools/test/scenarios/bin/find-flow.py b/framework/src/onos/tools/test/scenarios/bin/find-flow.py deleted file mode 100755 index a2f2e4d1..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/find-flow.py +++ /dev/null @@ -1,40 +0,0 @@ -#! /usr/bin/env python - -import requests -import sys - -from requests.auth import HTTPBasicAuth - -if len(sys.argv) != 4: - print "usage: find-flow onos-node name device-id" - sys.exit(1) - -node = sys.argv[1] -name = sys.argv[2] -deviceId = sys.argv[3] - -flowsRequest = requests.get('http://' + node + ':8181/onos/v1/flows/' + deviceId, - auth=HTTPBasicAuth('onos', 'rocks')) - -if flowsRequest.status_code != 200: - print flowsRequest.text - sys.exit(1) - -flowsJson = flowsRequest.json() - -for flow in flowsJson["flows"]: - if deviceId == flow["deviceId"]: - for criterion in flow["selector"]["criteria"]: - if criterion["type"] == 'IN_PORT' and criterion["port"] > 0: - for instruction in flow["treatment"]["instructions"]: - if instruction["port"] > 0 and instruction["type"] == 'OUTPUT': - print "@stc " + name + "FlowState=" + flow["state"] - print "@stc " + name + "FlowId=" + flow["id"] - print "@stc " + name + "FlowPort=" + str(instruction["port"]) - sys.exit(0) - -sys.exit(1) - - - - diff --git a/framework/src/onos/tools/test/scenarios/bin/find-host.py b/framework/src/onos/tools/test/scenarios/bin/find-host.py deleted file mode 100755 index e87a4090..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/find-host.py +++ /dev/null @@ -1,36 +0,0 @@ -#! /usr/bin/env python - -import requests -import sys -import urllib - -from requests.auth import HTTPBasicAuth - -if len(sys.argv) != 4: - print "usage: find-host onos-node name device-id" - sys.exit(1) - -node = sys.argv[1] -name = sys.argv[2] -id = sys.argv[3] - -hostRequest = requests.get('http://' + node + ':8181/onos/v1/hosts/' + - urllib.quote_plus(id), - auth=HTTPBasicAuth('onos', 'rocks')) - -if hostRequest.status_code != 200: - print hostRequest.text - sys.exit(1) - -hostJson = hostRequest.json() - -print "@stc " + name + "Id=" + hostJson["id"] -print "@stc " + name + "Mac=" + hostJson["mac"] -print "@stc " + name + "IpAddress=" + hostJson["ipAddresses"][0] - -sys.exit(0) - - - - - diff --git a/framework/src/onos/tools/test/scenarios/bin/find-link-in-cluster.py b/framework/src/onos/tools/test/scenarios/bin/find-link-in-cluster.py deleted file mode 100755 index 928531fd..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/find-link-in-cluster.py +++ /dev/null @@ -1,54 +0,0 @@ -#! /usr/bin/env python - -import requests -import sys - -from requests.auth import HTTPBasicAuth - -if len(sys.argv) != 9: - print "usage: find-link-in-cluster onos-node name cluster-id expected-length src-device-id src-port dst-device-id dst-port" - sys.exit(1) - -node = sys.argv[1] -name = sys.argv[2] -cluster = sys.argv[3] -length = int(sys.argv[4]) -srcDeviceId = sys.argv[5] -srcPort = sys.argv[6] -dstDeviceId = sys.argv[7] -dstPort = sys.argv[8] - - -linksRequest = requests.get('http://' + node + ':8181/onos/v1/topology/clusters/' - + cluster + '/links', - auth=HTTPBasicAuth('onos', 'rocks')) - -if linksRequest.status_code != 200: - print linksRequest.text - sys.exit(1) - -linksJson = linksRequest.json() -linksLength = len(linksJson["links"]) - -if linksLength != length: - print "Expected length {} but got {}".format(length, linksLength) - sys.exit(1) - -for link in linksJson["links"]: - if srcDeviceId == link["src"]["device"] and srcPort == link["src"]["port"]: - if dstDeviceId == link["dst"]["device"] and dstPort == link["dst"]["port"]: - print "@stc " + name + "SrcDevice=" + link["src"]["device"] - print "@stc " + name + "SrcPort=" + link["src"]["port"] - print "@stc " + name + "DstDevice=" + link["dst"]["device"] - print "@stc " + name + "DstPort=" + link["dst"]["port"] - print "@stc " + name + "Type=" + link["type"] - print "@stc " + name + "State=" + link["state"] - sys.exit(0) - -print "Could not find link from {}:{} to {}:{}"\ - .format(srcDeviceId, srcPort, dstDeviceId, dstPort) -sys.exit(1) - - - - diff --git a/framework/src/onos/tools/test/scenarios/bin/find-link.py b/framework/src/onos/tools/test/scenarios/bin/find-link.py deleted file mode 100755 index 9ac6e358..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/find-link.py +++ /dev/null @@ -1,45 +0,0 @@ -#! /usr/bin/env python - -import requests -import sys - -from requests.auth import HTTPBasicAuth - -if len(sys.argv) != 7: - print "usage: find-link onos-node name src-device-id src-port dst-device-id dst-port" - sys.exit(1) - -node = sys.argv[1] -name = sys.argv[2] -srcDeviceId = sys.argv[3] -srcPort = sys.argv[4] -dstDeviceId = sys.argv[5] -dstPort = sys.argv[6] - - -linksRequest = requests.get('http://' + node + ':8181/onos/v1/links?device=' + - srcDeviceId + '&port=' + srcPort, - auth=HTTPBasicAuth('onos', 'rocks')) - -if linksRequest.status_code != 200: - print linksRequest.text - sys.exit(1) - -linksJson = linksRequest.json() - -for link in linksJson["links"]: - if srcDeviceId == link["src"]["device"]: - if dstDeviceId == link["dst"]["device"]: - print "@stc " + name + "SrcDevice=" + link["src"]["device"] - print "@stc " + name + "SrcPort=" + link["src"]["port"] - print "@stc " + name + "DstDevice=" + link["dst"]["device"] - print "@stc " + name + "DstPort=" + link["dst"]["port"] - print "@stc " + name + "Type=" + link["type"] - print "@stc " + name + "State=" + link["state"] - sys.exit(0) - -sys.exit(1) - - - - diff --git a/framework/src/onos/tools/test/scenarios/bin/find-topo-infrastructure.py b/framework/src/onos/tools/test/scenarios/bin/find-topo-infrastructure.py deleted file mode 100755 index 6d1970f7..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/find-topo-infrastructure.py +++ /dev/null @@ -1,34 +0,0 @@ -#! /usr/bin/env python - -import requests -import sys -import urllib - -from requests.auth import HTTPBasicAuth - -if len(sys.argv) != 4: - print "usage: find-topo-infrastructure onos-node name connect-point" - sys.exit(1) - -node = sys.argv[1] -name = sys.argv[2] -id = sys.argv[3] - -infrastructureRequest = requests.get('http://' + node + ':8181/onos/v1/topology/infrastructure/' + - urllib.quote_plus(id), - auth=HTTPBasicAuth('onos', 'rocks')) - -if infrastructureRequest.status_code != 200: - print infrastructureRequest.text - sys.exit(1) - -infrastructureJson = infrastructureRequest.json() - -print "@stc " + name + "Infrastructure=" + str(infrastructureJson["infrastructure"]) - -sys.exit(0) - - - - - diff --git a/framework/src/onos/tools/test/scenarios/bin/query-cluster.py b/framework/src/onos/tools/test/scenarios/bin/query-cluster.py deleted file mode 100755 index 0cac7ac3..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/query-cluster.py +++ /dev/null @@ -1,37 +0,0 @@ -#! /usr/bin/env python - -import requests -import sys -import urllib - -from requests.auth import HTTPBasicAuth - -if len(sys.argv) != 4: - print "usage: query-cluster onos-node name cluster-number" - sys.exit(1) - -node = sys.argv[1] -name = sys.argv[2] -cluster = sys.argv[3] - -topoRequest = requests.get('http://' + node + ':8181/onos/v1/topology/clusters/' - + cluster, - auth=HTTPBasicAuth('onos', 'rocks')) - -if topoRequest.status_code != 200: - print topoRequest.text - sys.exit(1) - -topoJson = topoRequest.json() - -print "@stc " + name + "Id=" + str(topoJson["id"]) -print "@stc " + name + "DeviceCount=" + str(topoJson["deviceCount"]) -print "@stc " + name + "LinkCount=" + str(topoJson["linkCount"]) -print "@stc " + name + "Root=" + topoJson["root"] - -sys.exit(0) - - - - - diff --git a/framework/src/onos/tools/test/scenarios/bin/query-topo.py b/framework/src/onos/tools/test/scenarios/bin/query-topo.py deleted file mode 100755 index 9b81b4ee..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/query-topo.py +++ /dev/null @@ -1,35 +0,0 @@ -#! /usr/bin/env python - -import requests -import sys -import urllib - -from requests.auth import HTTPBasicAuth - -if len(sys.argv) != 3: - print "usage: query-topo onos-node name" - sys.exit(1) - -node = sys.argv[1] -name = sys.argv[2] - -topoRequest = requests.get('http://' + node + ':8181/onos/v1/topology/', - auth=HTTPBasicAuth('onos', 'rocks')) - -if topoRequest.status_code != 200: - print topoRequest.text - sys.exit(1) - -topoJson = topoRequest.json() - -print "@stc " + name + "Time=" + str(topoJson["time"]) -print "@stc " + name + "Devices=" + str(topoJson["devices"]) -print "@stc " + name + "Links=" + str(topoJson["links"]) -print "@stc " + name + "Clusters=" + str(topoJson["clusters"]) - -sys.exit(0) - - - - - diff --git a/framework/src/onos/tools/test/scenarios/bin/verify-topo-devices.py b/framework/src/onos/tools/test/scenarios/bin/verify-topo-devices.py deleted file mode 100755 index be834b9b..00000000 --- a/framework/src/onos/tools/test/scenarios/bin/verify-topo-devices.py +++ /dev/null @@ -1,51 +0,0 @@ -#! /usr/bin/env python - -import requests -import sys -import urllib - -from requests.auth import HTTPBasicAuth - -if len(sys.argv) != 5: - print "usage: verify-topo-links onos-node cluster-id first-index last-index" - sys.exit(1) - -node = sys.argv[1] -cluster = sys.argv[2] -first = int(sys.argv[3]) -last = int(sys.argv[4]) - -found = 0 - -topoRequest = requests.get('http://' + node + ':8181/onos/v1/topology/clusters/' - + cluster - + "/devices", - auth=HTTPBasicAuth('onos', 'rocks')) - -if topoRequest.status_code != 200: - print topoRequest.text - sys.exit(1) - -topoJson = topoRequest.json() - -for deviceIndex in range(first, last+1): - lookingFor = "of:" + format(deviceIndex, '016x') - print lookingFor - for arrayIndex in range(0, len(topoJson["devices"])): - device = topoJson["devices"][arrayIndex] - if device == lookingFor: - found = found + 1 - print "Match found for " + device - break - - -if found == last - first: - sys.exit(0) - -print "Found " + str(found) + " matches, need " + str(last - first) -sys.exit(2) - - - - - diff --git a/framework/src/onos/tools/test/scenarios/dist-test-seq.xml b/framework/src/onos/tools/test/scenarios/dist-test-seq.xml deleted file mode 100644 index 2e99fa27..00000000 --- a/framework/src/onos/tools/test/scenarios/dist-test-seq.xml +++ /dev/null @@ -1,67 +0,0 @@ -<!-- - ~ Copyright 20${OCI}5 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> - -<scenario name="dist-test" - description="ONOS distributed primitives setup"> - <group name="Distributed-Primitives"> - <!--<import file="${ONOS_SCENARIOS}/prerequisites.xml"/>--> - - <!--<import file="${ONOS_SCENARIOS}/setup.xml"/> - <dependency name="Setup" requires="Prerequisites"/>--> - - <sequential var="${OC#}" starts="Distributed-App-${#}" ends="Check-Distributed-Exceptions-${#-1}"> - <step name="Distributed-App-${#}" - requires="Setup" - exec="onos ${OC#} app activate org.onosproject.distributedprimitives"/> - - <step name="Test-Counter-Increment-${#}" - requires="Distributed-App-${#}" - exec="onos-execute-expect ${OC#} counter-test-increment fooCounter 5 --expect updated"/> - - <step name="Test-Add-${#}" - requires="Distributed-App-${#}" - exec="onos-execute-expect ${OC#} set-test-add fooSet foo --expect added"/> - - <step name="Test-Get-${#}" - requires="Test-Add-${#}" - exec="onos-execute-expect ${OC#} set-test-get fooSet foo --expect contains"/> - - <step name="Test-Remove-${#}" - requires="Test-Get-${#}" - exec="onos-execute-expect ${OC#} set-test-remove fooSet foo --expect removed"/> - - <step name="Test-Add-Multiple-${#}" - requires="Test-Remove-${#}" - exec="onos-execute-expect ${OC#} set-test-add fooSet foo foo2 foo3 --expect added"/> - - <step name="Test-Get-Multiple-${#}" - requires="Test-Add-Multiple-${#}" - exec="onos-execute-expect ${OC#} set-test-get fooSet foo foo2 foo3 --expect contains"/> - - <step name="Test-Remove-Multiple-${#}" - requires="Test-Get-Multiple-${#}" - exec="onos-execute-expect ${OC#} set-test-remove fooSet foo foo2 foo3 --expect removed"/> - - <step name="Sleep-${#}" - exec="sleep 2" - requires="Test-Remove-Multiple-${#}"/> - <!--Check with check logs--> - <step name="Check-Distributed-Exceptions-${#}" - exec="onos-check-logs ${OC#}" - requires="Sleep-${#}"/> - </sequential> - </group> -</scenario>
\ No newline at end of file diff --git a/framework/src/onos/tools/test/scenarios/dist-test.xml b/framework/src/onos/tools/test/scenarios/dist-test.xml deleted file mode 100644 index 5e7dab0b..00000000 --- a/framework/src/onos/tools/test/scenarios/dist-test.xml +++ /dev/null @@ -1,70 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. ---> - -<scenario name="dist-test" - description="ONOS distributed primitives setup"> - <group name="Distributed-Primitives"> - - <!--<import file="${ONOS_SCENARIOS}/setup.xml"/> - <dependency name="Setup" requires="Prerequisites"/>--> - - <step name="Distributed-App" - requires="Setup" - exec="onos ${OCI} app activate org.onosproject.distributedprimitives"/> - - <step name="Test-Counter-Increment" - requires="Distributed-App" - exec="onos-execute-expect ${OCI} counter-test-increment fooCounter 5 --expect updated"/> - - <step name="Test-Add" - requires="Distributed-App" - exec="onos-execute-expect ${OCI} set-test-add fooSet foo --expect added"/> - - <step name="Test-Get" - requires="Test-Add" - exec="onos-execute-expect ${OCI} set-test-get fooSet foo --expect contains"/> - - <step name="Test-Remove" - requires="Test-Get" - exec="onos-execute-expect ${OCI} set-test-remove fooSet foo --expect removed"/> - - <step name="Test-Add-Multiple" - requires="Test-Remove" - exec="onos-execute-expect ${OCI} set-test-add fooSet foo foo2 foo3 --expect added"/> - - <step name="Test-Get-Multiple" - requires="Test-Add-Multiple" - exec="onos-execute-expect ${OCI} set-test-get fooSet foo foo2 foo3 --expect contains"/> - - <step name="Test-Remove-Multiple" - requires="Test-Get-Multiple" - exec="onos-execute-expect ${OCI} set-test-remove fooSet foo foo2 foo3 --expect removed"/> - - <step name="Test-Map-Put" - requires="Distributed-App" - exec="onos-execute-expect ${OCI} transactional-map-test-put 1 foo --expect Created"/> - - <step name="Test-Map-Get" - requires="Test-Map-Put" - exec="onos-execute-expect ${OCI} transactional-map-test-get Key1 --expect Key-value"/> - - <!--Check with check logs--> - <step name="Check-Distributed-Exceptions" - exec="onos-check-logs ${OCI}" - requires="Test-Map-Get"/> - </group> -</scenario> - diff --git a/framework/src/onos/tools/test/scenarios/example.xml b/framework/src/onos/tools/test/scenarios/example.xml deleted file mode 100644 index 65803141..00000000 --- a/framework/src/onos/tools/test/scenarios/example.xml +++ /dev/null @@ -1,19 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="example" description="Example"> - <step name="One" exec="echo @stc foo=bar"/> - <step name="Two" requires="One" exec="echo ${foo}"/> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/fast.xml b/framework/src/onos/tools/test/scenarios/fast.xml deleted file mode 100644 index 0d38c456..00000000 --- a/framework/src/onos/tools/test/scenarios/fast.xml +++ /dev/null @@ -1,30 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="fast" description="ONOS fast smoke test"> - <import file="${ONOS_SCENARIOS}/prerequisites.xml"/> - - <import file="${ONOS_SCENARIOS}/setup.xml"/> - <dependency name="Setup" requires="Prerequisites"/> - - <import file="${ONOS_SCENARIOS}/net-fast.xml"/> - <dependency name="Net-Fast" requires="Setup"/> - - <import file="${ONOS_SCENARIOS}/archetypes.xml"/> - <dependency name="Archetypes" requires="Setup"/> - - <import file="${ONOS_SCENARIOS}/wrapup.xml"/> - <dependency name="Wrapup" requires="Prerequisites,~Archetypes,~Setup,~Net-Fast"/> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/net-create-flows.xml b/framework/src/onos/tools/test/scenarios/net-create-flows.xml deleted file mode 100644 index 6a6a80b0..00000000 --- a/framework/src/onos/tools/test/scenarios/net-create-flows.xml +++ /dev/null @@ -1,93 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-create-flows" - description="Network Flow Creation Test Using REST API"> - <!-- TODO: parametrize this via recipes --> - <group name="Net-Create-Flows"> - - <!-- Make sure that reactive forwarding is off --> - <step name="Net-Create-Flows.Uninstall-Reactive-Forwarding" - exec="onos ${OC1} app deactivate org.onosproject.fwd org.onosproject.ifwd"/> - <step name="Net-Create-Flows.Check-Apps" requires="^" - exec="onos-check-apps ${OC1} fwd,ifwd excludes"/> - - <!-- Force discovery of hosts --> - <step name="Net-Create-Flows.Find-Host-1" requires="^" - exec="onos-mininet sendAndExpect h1 ping -c1 -w1 h4 --expect 100% packet loss"/> - <step name="Net-Create-Flows.Find-Host-2" requires="^" - exec="onos-mininet sendAndExpect h4 ping -c1 -w1 h1 --expect 100% packet loss"/> - - - <!-- Use REST API to create a point to point intent in each direction --> - <step name="Net-Create-Flows.1-to-Host" requires="Net-Create-Flows.Find-Host-2" - exec="create-flow.py ${OC1} f1 of:0000000000000001 5 1"/> - <step name="Net-Create-Flows.1-to-19" requires="^" - exec="create-flow.py ${OC1} f2 of:0000000000000001 1 2"/> - <step name="Net-Create-Flows.19-to-7" requires="^" - exec="create-flow.py ${OC1} f3 of:0000000000000019 2 8"/> - <step name="Net-Create-Flows.7-to-4" requires="^" - exec="create-flow.py ${OC1} f4 of:0000000000000007 2 3"/> - <step name="Net-Create-Flows.4-to-Host" requires="^" - exec="create-flow.py ${OC1} f5 of:0000000000000004 1 3"/> - - <step name="Net-Create-Flows.Host-to-1" requires="^" - exec="create-flow.py ${OC1} f6 of:0000000000000001 1 5"/> - <step name="Net-Create-Flows.19-to-1" requires="^" - exec="create-flow.py ${OC1} f7 of:0000000000000001 2 1"/> - <step name="Net-Create-Flows.7-to-19" requires="^" - exec="create-flow.py ${OC1} f8 of:0000000000000019 8 2"/> - <step name="Net-Create-Flows.4-to-7" requires="^" - exec="create-flow.py ${OC1} f9 of:0000000000000007 3 2"/> - <step name="Net-Create-Flows.Host-to-4" requires="^" - exec="create-flow.py ${OC1} f10 of:0000000000000004 3 1"/> - - <!-- Check that connectivity was established --> - <step name="Net-Create-Flows.Ping-XY" requires="^" - exec="onos-mininet sendAndExpect h1 ping -c1 h4 --expect \ 0% packet loss"/> - <step name="Net-Create-Flows.Ping-YX" requires="^" - exec="onos-mininet sendAndExpect h4 ping -c1 h1 --expect \ 0% packet loss"/> - - <!-- Use REST API to remove the flows. --> - <step name="Net-Create-Flows.Delete-f1" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${f1Location}"/> - <step name="Net-Create-Flows.Delete-f2" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${f2Location}"/> - <step name="Net-Create-Flows.Delete-f3" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${f3Location}"/> - <step name="Net-Create-Flows.Delete-f4" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${f4Location}"/> - <step name="Net-Create-Flows.Delete-f5" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${f5Location}"/> - <step name="Net-Create-Flows.Delete-f6" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${f6Location}"/> - <step name="Net-Create-Flows.Delete-f7" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${f7Location}"/> - <step name="Net-Create-Flows.Delete-f8" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${f8Location}"/> - <step name="Net-Create-Flows.Delete-f9" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${f9Location}"/> - <step name="Net-Create-Flows.Delete-f10" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${f10Location}"/> - - <!-- Ping again to be sure the path was removed. --> - <step name="Net-Create-Flows.Fail-Ping-XY" requires="^" - exec="onos-mininet sendAndExpect h1 ping -c1 h4 --expect \ 100% packet loss"/> - <step name="Net-Create-Flows.Fail-Ping-YX" requires="^" - exec="onos-mininet sendAndExpect h4 ping -c1 h1 --expect \ 100% packet loss"/> - - - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/net-fast.xml b/framework/src/onos/tools/test/scenarios/net-fast.xml deleted file mode 100644 index 359c0082..00000000 --- a/framework/src/onos/tools/test/scenarios/net-fast.xml +++ /dev/null @@ -1,29 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-fast" description="Basic network functionality fast test"> - <group name="Net-Fast"> - <import file="${ONOS_SCENARIOS}/net-setup.xml"/> - - <import file="${ONOS_SCENARIOS}/net-pingall.xml" namespace="Reactive-Forwarding"/> - <dependency name="Reactive-Forwarding.Net-Pingall" requires="Net-Setup"/> - - <import file="${ONOS_SCENARIOS}/net-link-down-up.xml" namespace="Reactive-Forwarding"/> - <dependency name="Reactive-Forwarding.Net-Link-Down-Up" requires="Net-Setup,~Reactive-Forwarding.Net-Pingall"/> - - <import file="${ONOS_SCENARIOS}/net-teardown.xml"/> - <dependency name="Net-Teardown" requires="~Reactive-Forwarding.Net-Link-Down-Up"/> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/net-host-intent.xml b/framework/src/onos/tools/test/scenarios/net-host-intent.xml deleted file mode 100644 index fbf8c4ab..00000000 --- a/framework/src/onos/tools/test/scenarios/net-host-intent.xml +++ /dev/null @@ -1,59 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-host-intent" description="Network host intent connectivity test"> - <!-- TODO: parametrize this via recipes --> - <group name="Host-Intent-Connectivity"> - <step name="Host-Intent.Uninstall-Reactive-Forwarding" - exec="onos ${OC1} app deactivate org.onosproject.fwd org.onosproject.ifwd"/> - <step name="Host-Intent.Check-Apps" requires="^" - exec="onos-check-apps ${OC1} fwd,ifwd excludes"/> - - <step name="Host-Intent.Find-Host-1" requires="^" - exec="onos-mininet sendAndExpect h1 ping -c1 -w1 h4 --expect ."/> - <step name="Host-Intent.Find-Host-2" requires="^" - exec="onos-mininet sendAndExpect h4 ping -c1 -w1 h1 --expect ."/> - - <step name="Host-Intent.Create-Intent" requires="^" - exec="onos-create-intent ${OC1} h2h host 00:00:00:00:00:01/-1 00:00:00:00:00:04/-1"/> - <step name="Host-Intent.Validate-Intent-Installed" requires="Host-Intent.Create-Intent" - exec="onos-check-intent ${OC1} h2h INSTALLED"/> - - <import file="${ONOS_SCENARIOS}/net-link-down-up.xml" namespace="Host-Intent"/> - <dependency name="Host-Intent.Net-Link-Down-Up" - requires="Host-Intent.Validate-Intent-Installed"/> - - <step name="Host-Intent.Validate-Intent-Installed-Still" requires="Host-Intent.Link-1-Down" - exec="onos-check-intent ${OC1} h2h INSTALLED"/> - - <dependency name="Host-Intent.Link-2-Down" - requires="~Host-Intent.Validate-Intent-Installed-Still" /> - - <step name="Host-Intent.Validate-Intent-Failed" requires="Host-Intent.Link-2-Down" - exec="onos-check-intent ${OC1} h2h FAILED"/> - - <dependency name="Host-Intent.Link-1-Up" - requires="~Host-Intent.Validate-Intent-Failed" /> - - <step name="Host-Intent.Validate-Intent-Installed-Again" requires="Host-Intent.Link-1-Up" - exec="onos-check-intent ${OC1} h2h INSTALLED"/> - - <dependency name="Host-Intent.Ping-4" - requires="~Host-Intent.Validate-Intent-Installed-Again" /> - - <step name="Host-Intent.Remove-Intent" requires="~Host-Intent.Net-Link-Down-Up" - exec="onos ${OC1} remove-intent -p org.onosproject.cli h2h"/> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/net-link-down-up.xml b/framework/src/onos/tools/test/scenarios/net-link-down-up.xml deleted file mode 100644 index eb4727bd..00000000 --- a/framework/src/onos/tools/test/scenarios/net-link-down-up.xml +++ /dev/null @@ -1,44 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-link-down-up" description="Network link up-down test"> - <!-- TODO: parametrize this via recipes --> - <group name="Net-Link-Down-Up"> - <step name="Ping-1" - exec="onos-mininet sendAndExpect h1 ping -c1 h4 --expect \ 0% packet loss"/> - <step name="Link-1-Down" requires="~Ping-1" - exec="onos-mininet sendAndExpect link s4 s7 down --expect ."/> - <step name="Ping-2-Prep" requires="~Link-1-Down" - exec="onos-mininet sendAndExpect h1 ping -c5 h4 --expect ."/> - <step name="Ping-2" requires="~Ping-2-Prep" - exec="onos-mininet sendAndExpect h1 ping -c1 h4 --expect \ 0% packet loss"/> - <step name="Link-2-Down" requires="~Ping-2" - exec="onos-mininet sendAndExpect link s4 s5 down --expect ."/> - <step name="Ping-3" requires="~Link-2-Down" - exec="onos-mininet sendAndExpect h1 ping -c1 -w1 h4 --expect 100% packet loss"/> - <step name="Link-1-Up" requires="~Ping-3" - exec="onos-mininet sendAndExpect link s4 s7 up --expect ."/> - <step name="Ping-4-Prep" requires="~Link-1-Up" - exec="onos-mininet sendAndExpect h1 ping -c5 h4 --expect ."/> - <step name="Ping-4" requires="~Ping-4-Prep" - exec="onos-mininet sendAndExpect h1 ping -c1 h4 --expect \ 0% packet loss"/> - <step name="Link-2-Up" requires="~Ping-4" - exec="onos-mininet sendAndExpect link s4 s5 up --expect ."/> - <step name="Ping-5-Prep" requires="~Link-2-Up" - exec="onos-mininet sendAndExpect h1 ping -c5 h4 --expect ."/> - <step name="Ping-5" requires="~Ping-5-Prep" - exec="onos-mininet sendAndExpect h1 ping -c1 h4 --expect \ 0% packet loss"/> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/net-pingall.xml b/framework/src/onos/tools/test/scenarios/net-pingall.xml deleted file mode 100644 index 100cebac..00000000 --- a/framework/src/onos/tools/test/scenarios/net-pingall.xml +++ /dev/null @@ -1,37 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-pingall" description="Network pingall test"> - <!-- TODO: parametrize this via recipes --> - <group name="Net-Pingall"> - <step name="Install-Apps" - exec="onos ${OC1} app activate org.onosproject.openflow org.onosproject.proxyarp org.onosproject.fwd"/> - <step name="Check-Apps" requires="^" - exec="onos-check-apps ${OC1} drivers,openflow,proxyarp,fwd includes"/> - - <!-- TODO: take this out when initial pingall sweep is 100% --> - <step name="Initial-Ping-All" requires="Check-Apps" unless="${ONOS_RF_BUG_FIXED}" - exec="onos-mininet sendAndExpect py net.pingAll(1) --expect received"/> - - <step name="Ping-All-And-Verify" requires="Check-Apps,Initial-Ping-All" - exec="onos-mininet sendAndExpect py net.pingAll(1) --expect 600/600 received"/> - - <step name="Check-Summary-For-Hosts" requires="~Ping-All-And-Verify" - exec="onos-check-summary ${OC1} [0-9]* 25 140 25"/> - - <step name="Config-Topo" requires="~Check-Summary-For-Hosts" - exec="onos-topo-cfg ${OC1} ${ONOS_ROOT}/tools/test/topos/attmpls.json"/> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/net-point-intent.xml b/framework/src/onos/tools/test/scenarios/net-point-intent.xml deleted file mode 100644 index acb8212b..00000000 --- a/framework/src/onos/tools/test/scenarios/net-point-intent.xml +++ /dev/null @@ -1,77 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-point-intent" - description="Network point to point intent connectivity test"> - <!-- TODO: parametrize this via recipes --> - <group name="P2P-Intent-Connectivity"> - <step name="P2P-Intent.Uninstall-Reactive-Forwarding" - exec="onos ${OC1} app deactivate org.onosproject.fwd org.onosproject.ifwd"/> - <step name="P2P-Intent.Check-Apps" requires="^" - exec="onos-check-apps ${OC1} fwd,ifwd excludes"/> - - <step name="P2P-Intent.Find-Host-1" requires="^" - exec="onos-mininet sendAndExpect h1 ping -c1 -w1 h4 --expect ."/> - <step name="P2P-Intent.Find-Host-2" requires="^" - exec="onos-mininet sendAndExpect h4 ping -c1 -w1 h1 --expect ."/> - - <step name="P2P-Intent.Create-Intent-XY" requires="^" - exec="onos-create-intent ${OC1} xy point of:0000000000000001/1 of:0000000000000004/1"/> - <step name="P2P-Intent.Create-Intent-YX" requires="^" - exec="onos-create-intent ${OC1} yx point of:0000000000000004/1 of:0000000000000001/1"/> - - <step name="P2P-Intent.Validate-Intent-XY-Installed" requires="^" - exec="onos-check-intent ${OC1} yx INSTALLED"/> - <step name="P2P-Intent.Validate-Intent-YX-Installed" requires="^" - exec="onos-check-intent ${OC1} xy INSTALLED"/> - - <import file="${ONOS_SCENARIOS}/net-link-down-up.xml" namespace="P2P-Intent"/> - <dependency name="P2P-Intent.Net-Link-Down-Up" - requires="P2P-Intent.Validate-Intent-XY-Installed, - P2P-Intent.Validate-Intent-YX-Installed"/> - - <step name="P2P-Intent.Validate-Intent-XY-Installed-Still" requires="P2P-Intent.Link-1-Down" - exec="onos-check-intent ${OC1} xy INSTALLED"/> - <step name="P2P-Intent.Validate-Intent-YX-Installed-Still" requires="P2P-Intent.Link-1-Down" - exec="onos-check-intent ${OC1} yx INSTALLED"/> - - <dependency name="P2P-Intent.Link-2-Down" - requires="~P2P-Intent.Validate-Intent-XY-Installed-Still, - ~P2P-Intent.Validate-Intent-YX-Installed-Still"/> - - <step name="P2P-Intent.Validate-Intent-XY-Failed" requires="P2P-Intent.Link-2-Down" - exec="onos-check-intent ${OC1} xy FAILED"/> - <step name="P2P-Intent.Validate-Intent-YX-Failed" requires="P2P-Intent.Link-2-Down" - exec="onos-check-intent ${OC1} yx FAILED"/> - - <dependency name="P2P-Intent.Link-1-Up" - requires="~P2P-Intent.Validate-Intent-XY-Failed, - ~P2P-Intent.Validate-Intent-YX-Failed" /> - - <step name="P2P-Intent.Validate-Intent-XY-Installed-Again" requires="P2P-Intent.Link-1-Up" - exec="onos-check-intent ${OC1} xy INSTALLED"/> - <step name="P2P-Intent.Validate-Intent-YX-Installed-Again" requires="P2P-Intent.Link-1-Up" - exec="onos-check-intent ${OC1} yx INSTALLED"/> - - <dependency name="P2P-Intent.Ping-4" - requires="~P2P-Intent.Validate-Intent-XY-Installed-Again, - ~P2P-Intent.Validate-Intent-YX-Installed-Again"/> - - <step name="P2P-Intent.Remove-Intent-XY" requires="~P2P-Intent.Net-Link-Down-Up" - exec="onos ${OC1} remove-intent -p org.onosproject.cli xy"/> - <step name="P2P-Intent.Remove-Intent-YX" requires="~P2P-Intent.Net-Link-Down-Up" - exec="onos ${OC1} remove-intent -p org.onosproject.cli yx"/> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/net-rest.xml b/framework/src/onos/tools/test/scenarios/net-rest.xml deleted file mode 100644 index ab7804df..00000000 --- a/framework/src/onos/tools/test/scenarios/net-rest.xml +++ /dev/null @@ -1,161 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-rest" - description="Network REST API test"> - <!-- TODO: parametrize this via recipes --> - <group name="Net-REST"> - - <!-- Make sure that reactive forwarding is off --> - <step name="Net-REST.Uninstall-Reactive-Forwarding" - exec="onos ${OC1} app deactivate org.onosproject.fwd org.onosproject.ifwd"/> - <step name="Net-REST.Check-Apps" requires="^" - exec="onos-check-apps ${OC1} fwd,ifwd excludes"/> - - <!-- Force discovery of hosts --> - <step name="Net-REST.Find-Host-1" requires="^" - exec="onos-mininet sendAndExpect h1 ping -c1 -w1 h4 --expect ."/> - <step name="Net-REST.Find-Host-2" requires="^" - exec="onos-mininet sendAndExpect h4 ping -c1 -w1 h1 --expect ."/> - - <!-- Verify some links using the REST API --> - <step name="Net-REST.Query-Link-1" requires="Net-REST.Find-Host-2" - exec="find-link.py ${OC1} link1 of:0000000000000001 5 of:0000000000000006 4"/> - <step name="Net-REST.Validate-Link-1-State" requires="^" - exec="test '${link1State}' == 'ACTIVE'"/> - <step name="Net-REST.Validate-Link-1-Type" requires="^" - exec="test '${link1Type}' == 'DIRECT'"/> - <step name="Net-REST.Validate-Link-1-Src-Device" requires="^" - exec="test '${link1SrcDevice}' == 'of:0000000000000001'"/> - <step name="Net-REST.Validate-Link-1-Dst-Device" requires="^" - exec="test '${link1DstDevice}' == 'of:0000000000000006'"/> - <step name="Net-REST.Validate-Link-1-Src-Port" requires="^" - exec="test '${link1SrcPort}' == '5'"/> - <step name="Net-REST.Validate-Link-1-Dst-Port" requires="^" - exec="test '${link1DstPort}' == '4'"/> - - <step name="Net-REST.Query-Link-2" requires="Net-REST.Find-Host-2" - exec="find-link.py ${OC1} link2 of:0000000000000019 7 of:0000000000000006 3"/> - <step name="Net-REST.Validate-Link-2-State" requires="^" - exec="test '${link2State}' == 'ACTIVE'"/> - <step name="Net-REST.Validate-Link-2-Type" requires="^" - exec="test '${link2Type}' == 'DIRECT'"/> - <step name="Net-REST.Validate-Link-2-Src-Device" requires="^" - exec="test '${link2SrcDevice}' == 'of:0000000000000019'"/> - <step name="Net-REST.Validate-Link-2-Dst-Device" requires="^" - exec="test '${link2DstDevice}' == 'of:0000000000000006'"/> - <step name="Net-REST.Validate-Link-2-Src-Port" requires="^" - exec="test '${link2SrcPort}' == '7'"/> - <step name="Net-REST.Validate-Link-2-Dst-Port" requires="^" - exec="test '${link2DstPort}' == '3'"/> - - <!-- Verify the hosts using the REST API --> - <step name="Net-REST.Query-Host-1" requires="Net-REST.Find-Host-2" - exec="find-host.py ${OC1} host1 00:00:00:00:00:01/-1"/> - <step name="Net-REST.Validate-Host-1-Id" requires="^" - exec="test '${host1Id}' == '00:00:00:00:00:01/-1'"/> - <step name="Net-REST.Validate-Host-1-Mac" requires="^" - exec="test '${host1Mac}' == '00:00:00:00:00:01'"/> - <step name="Net-REST.Validate-Host-1-Ip" requires="^" - exec="test '${host1IpAddress}' == '10.0.0.1'"/> - - <step name="Net-REST.Query-Host-2" requires="Net-REST.Find-Host-2" - exec="find-host.py ${OC1} host2 00:00:00:00:00:04/-1"/> - <step name="Net-REST.Validate-Host-2-Id" requires="^" - exec="test '${host2Id}' == '00:00:00:00:00:04/-1'"/> - <step name="Net-REST.Validate-Host-2-Mac" requires="^" - exec="test '${host2Mac}' == '00:00:00:00:00:04'"/> - <step name="Net-REST.Validate-Host-2-Ip" requires="^" - exec="test '${host2IpAddress}' == '10.0.0.4'"/> - - <!-- Verify a switch using the REST API --> - <step name="Net-REST.Query-Dev-1" requires="Net-REST.Find-Host-2" - exec="find-device.py ${OC1} dev1 of:0000000000000014"/> - <step name="Net-REST.Validate-Dev1-Id" requires="^" - exec="test '${dev1Id}' == 'of:0000000000000014'"/> - <step name="Net-REST.Validate-Dev1-Type" requires="^" - exec="test '${dev1Type}' == 'SWITCH'"/> - <step name="Net-REST.Validate-Dev1-Available" requires="^" - exec="test '${dev1Available}' == 'True'"/> - <step name="Net-REST.Validate-Dev1-ChannelId" requires="^" - exec="test '${dev1IpAddress}' == '${OCN}'"/> - - <!-- Use REST API to create a point to point intent in each direction --> - <step name="Net-REST.Create-Intent-XY" requires="Net-REST.Find-Host-2" - exec="create-intent.py ${OC1} xy of:0000000000000001 1 of:0000000000000004 1"/> - <step name="Net-REST.Create-Intent-YX" requires="^" - exec="create-intent.py ${OC1} yx of:0000000000000004 1 of:0000000000000001 1"/> - - <!-- Check that the intents can be fetched via the REST API --> - <step name="Net-REST.Validate-Intent-XY-Installed" - requires="Net-REST.Create-Intent-YX" - exec="curl-with-retry ${xyLocation}"/> - <step name="Net-REST.Validate-Intent-YX-Installed" - requires="^" - exec="curl-with-retry ${yxLocation}"/> - - <!-- Use REST API to query flows created by the intents --> - <step name="Net-REST.Validate-Intent-XY-Flow-Installed" - requires="Net-REST.Create-Intent-YX" - exec="find-flow.py ${OC1} dev1out of:0000000000000001"/> - <step name="Net-REST.Validate-XY-Flow-State" requires="^" - exec="test '${dev1outFlowState}' == 'ADDED' -o '${dev1outFlowState}' == 'PENDING_ADD'"/> - <step name="Net-REST.Validate-XY-Flow-Port" requires="^" - exec="test ${dev1outFlowPort} -ge 1 -a ${dev1outFlowPort} -le 5"/> - - <step name="Net-REST.Validate-Intent-YX-Flow-Installed" requires="Net-REST.Create-Intent-YX" - exec="find-flow.py ${OC1} dev4out of:0000000000000004"/> - <step name="Net-REST.Validate-YX-Flow-State" requires="^" - exec="test '${dev4outFlowState}' == 'ADDED' -o '${dev4outFlowState}' == 'PENDING_ADD'"/> - <step name="Net-REST.Validate-YX-Flow-Port" requires="^" - exec="test ${dev4outFlowPort} -ge 1 -a ${dev4outFlowPort} -le 5"/> - - <!-- Check that connectivity was established --> - <step name="Net-REST.Ping-XY" requires="Net-REST.Create-Intent-XY,Net-REST.Create-Intent-YX" - exec="onos-mininet sendAndExpect h1 ping -c1 h4 --expect \ 0% packet loss"/> - <step name="Net-REST.Ping-YX" requires="^" - exec="onos-mininet sendAndExpect h4 ping -c1 h1 --expect \ 0% packet loss"/> - - <!-- Remove the intents via the REST API --> - <step name="Net-REST.Delete-Intent-XY" - requires="Net-REST.Validate-Intent-XY-Installed, - Net-REST.Validate-Intent-YX-Installed, - Net-REST.Validate-Intent-XY-Flow-Installed, - Net-REST.Validate-Intent-YX-Flow-Installed, - Net-REST.Ping-XY, - Net-REST.Ping-YX" - exec="curl -f -X DELETE -uonos:rocks ${xyLocation}"/> - <step name="Net-REST.Delete-Intent-YX" requires="^" - exec="curl -f -X DELETE -uonos:rocks ${yxLocation}"/> - <step name="Net-REST.Allow-Intents-To-Purge" - exec="onos-check-intent ${OC1} xy INSTALLED" env="!" - requires="Net-REST.Delete-Intent-XY,Net-REST.Delete-Intent-YX"/> - - <!-- Use REST API to be sure that flows are no longer installed --> - <step name="Net-REST.Validate-XY-Flows-Removed" requires="Net-REST.Allow-Intents-To-Purge" - exec="find-flow.py ${OC1} dev1out of:0000000000000001" - env="!"/> - <step name="Net-REST.Validate-YX-Flows-Removed" requires="Net-REST.Allow-Intents-To-Purge" - exec="find-flow.py ${OC1} dev4out of:0000000000000004" - env="!"/> - - <!-- Check that the deleted intents no longer appear in the REST API --> - <step name="Net-REST.Validate-Intent-XY-Removed" requires="Net-REST.Allow-Intents-To-Purge" - exec="curl-with-retry ${xyLocation}" env="!"/> - <step name="Net-REST.Validate-Intent-YX-Removed" requires="Net-REST.Allow-Intents-To-Purge" - exec="curl-with-retry ${yxLocation}" env="!"/> - - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/net-setup.xml b/framework/src/onos/tools/test/scenarios/net-setup.xml deleted file mode 100644 index 13252d0f..00000000 --- a/framework/src/onos/tools/test/scenarios/net-setup.xml +++ /dev/null @@ -1,46 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-setup" description="Network setup steps"> - <!-- TODO: parametrize this via recipes --> - <group name="Net-Setup"> - <step name="Push-Topos" exec="onos-push-topos ${OCN}"/> - - <step name="Stop-Mininet-If-Needed" env="~" exec="onos-mininet stop"/> - <step name="Wipe-Out-Data-Before" exec="onos-wipe-out" requires="^"/> - - <step name="Initial-Summary-Check" requires="~Wipe-Out-Data-Before" - exec="onos-check-summary ${OC1} [0-9]* 0 0 0"/> - - <step name="Start-Mininet" - requires="Install-Apps,Initial-Summary-Check,Push-Topos,Stop-Mininet-If-Needed" - exec="onos-mininet start topos/topo att-onos.py ${ONOS_INSTANCES}"/> - - <step name="Wait-For-Mininet" requires="Start-Mininet" - exec="onos-mininet wait 10"/> - - <step name="Check-Summary" requires="Wait-For-Mininet" - exec="onos-check-summary ${OC1} [0-9]* 25 140 0"/> - - <step name="Balance-Masters" requires="~Check-Summary" if="${OC2}" - exec="onos ${OC1} balance-masters"/> - - <step name="Pause-For-Masters" requires="Balance-Masters" if="${OC2}" - exec="sleep 10"/> - - <step name="Check-Flows" requires="~Pause-For-Masters,~Check-Summary" - exec="onos-check-flows ${OC1}"/> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/net-smoke.xml b/framework/src/onos/tools/test/scenarios/net-smoke.xml deleted file mode 100644 index 037b6f00..00000000 --- a/framework/src/onos/tools/test/scenarios/net-smoke.xml +++ /dev/null @@ -1,48 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-smoke" description="Basic network functionality smoke test"> - <group name="Net-Smoke"> - <import file="${ONOS_SCENARIOS}/net-setup.xml"/> - - <import file="${ONOS_SCENARIOS}/net-pingall.xml" namespace="Reactive-Forwarding"/> - <dependency name="Reactive-Forwarding.Net-Pingall" requires="Net-Setup"/> - - <import file="${ONOS_SCENARIOS}/net-link-down-up.xml" namespace="Reactive-Forwarding"/> - <dependency name="Reactive-Forwarding.Net-Link-Down-Up" requires="Net-Setup,~Reactive-Forwarding.Net-Pingall"/> - - <import file="${ONOS_SCENARIOS}/net-host-intent.xml"/> - <dependency name="Host-Intent-Connectivity" requires="Net-Setup,~Reactive-Forwarding.Net-Link-Down-Up"/> - - <import file="${ONOS_SCENARIOS}/net-point-intent.xml"/> - <dependency name="P2P-Intent-Connectivity" requires="Net-Setup,~Reactive-Forwarding.Net-Link-Down-Up,Host-Intent-Connectivity"/> - - <import file="${ONOS_SCENARIOS}/net-rest.xml"/> - <dependency name="Net-REST" requires="Net-Setup,P2P-Intent-Connectivity"/> - - <import file="${ONOS_SCENARIOS}/net-create-flows.xml"/> - <dependency name="Net-Create-Flows" requires="Net-Setup,P2P-Intent-Connectivity,Net-REST"/> - - <import file="${ONOS_SCENARIOS}/net-topo.xml"/> - <dependency name="Net-Topo" requires="Net-Setup,Net-Create-Flows"/> - - <import file="${ONOS_SCENARIOS}/net-teardown.xml"/> - <dependency name="Net-Teardown" requires="~Host-Intent-Connectivity, - ~P2P-Intent-Connectivity, - ~Net-REST, - ~Net-Create-Flows, - ~Net-Topo"/> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/net-teardown.xml b/framework/src/onos/tools/test/scenarios/net-teardown.xml deleted file mode 100644 index a5d93ee2..00000000 --- a/framework/src/onos/tools/test/scenarios/net-teardown.xml +++ /dev/null @@ -1,21 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-setup" description="Network teardown steps"> - <group name="Net-Teardown"> - <step name="Stop-Mininet" exec="onos-mininet stop"/> - <XXXstep name="Wipe-Out-Data-After" requires="~Stop-Mininet" exec="onos-wipe-out"/> - </group> -</scenario>
\ No newline at end of file diff --git a/framework/src/onos/tools/test/scenarios/net-topo.xml b/framework/src/onos/tools/test/scenarios/net-topo.xml deleted file mode 100644 index cd720888..00000000 --- a/framework/src/onos/tools/test/scenarios/net-topo.xml +++ /dev/null @@ -1,76 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="net-topo" - description="Network topology test"> - <!-- TODO: parametrize this via recipes --> - <group name="Net-Topo"> - - <!-- Verify the overall topology using the REST API --> - <step name="Net-Topo.Query-Topo" - exec="query-topo.py ${OC1} topo"/> - <step name="Net-Topo.Verify-Topo-Devices" requires="Net-Topo.Query-Topo" - exec="test ${topoDevices} == 25"/> - <step name="Net-Topo.Verify-Topo-Links" requires="Net-Topo.Query-Topo" - exec="test ${topoLinks} == 140"/> - <step name="Net-Topo.Verify-Topo-Clusters" requires="Net-Topo.Query-Topo" - exec="test ${topoClusters} == 1"/> - - <!-- Verify the cluster topology using the REST API --> - <step name="Net-Topo.Query-Cluster0" - exec="query-cluster.py ${OC1} clusterTopo0 0"/> - <step name="Net-Topo.Verify-Cluster0-Id" requires="Net-Topo.Query-Cluster0" - exec="test ${clusterTopo0Id} == 0"/> - <step name="Net-Topo.Verify-Cluster0-DeviceCount" requires="Net-Topo.Query-Cluster0" - exec="test ${clusterTopo0DeviceCount} == 25"/> - <step name="Net-Topo.Verify-Cluster0-LinkCount" requires="Net-Topo.Query-Cluster0" - exec="test ${clusterTopo0LinkCount} == 140"/> - <step name="Net-Topo.Verify-Cluster0-Root" requires="Net-Topo.Query-Cluster0" - exec="test '${clusterTopo0Root}' == 'of:000000000000000a' -o '${clusterTopo0Root}' == 'of:000000000000000c'"/> - - <!-- Verify the list of devices for the cluster --> - <step name="Net-Topo.Verify-Cluster0-Devices" - exec="verify-topo-devices.py ${OC1} 0 0 24"/> - - <!-- Spot check some known links in the topology --> - <step name="Net-Topo.Verify-Cluster0-Link1" - exec="find-link-in-cluster.py ${OC1} link1 0 140 of:000000000000000f 8 of:0000000000000015 3"/> - <step name="Net-Topo.Verify-Cluster0-Link2" - exec="find-link-in-cluster.py ${OC1} link2 0 140 of:0000000000000008 3 of:0000000000000005 4"/> - <step name="Net-Topo.Verify-Cluster0-Link3" - exec="find-link-in-cluster.py ${OC1} link3 0 140 of:0000000000000011 2 of:0000000000000002 9"/> - <step name="Net-Topo.Verify-Cluster0-Link4" - exec="find-link-in-cluster.py ${OC1} link4 0 140 of:000000000000000f 3 of:000000000000000d 10"/> - <step name="Net-Topo.Verify-Cluster0-Link5" - exec="find-link-in-cluster.py ${OC1} link5 0 140 of:000000000000000d 13 of:0000000000000010 6"/> - - <!-- Verify the topology infrastructure query --> - <step name="Net-Topo.Query-Cluster0-Infra1" - exec="find-topo-infrastructure.py ${OC1} infra1 of:000000000000000f:8"/> - <step name="Net-Topo.Verify-Cluster0-Infra1" requires="Net-Topo.Query-Cluster0-Infra1" - exec="test '${infra1Infrastructure}' == 'True'"/> - - <step name="Net-Topo.Query-Cluster0-Infra2" - exec="find-topo-infrastructure.py ${OC1} infra2 of:000000000000000d:8"/> - <step name="Net-Topo.Verify-Cluster0-Infra2" requires="Net-Topo.Query-Cluster0-Infra2" - exec="test '${infra2Infrastructure}' == 'True'"/> - - <step name="Net-Topo.Query-Cluster0-Infra3" - exec="find-topo-infrastructure.py ${OC1} infra3 of:0000000000000012:8"/> - <step name="Net-Topo.Verify-Cluster0-Infra3" requires="Net-Topo.Query-Cluster0-Infra3" - exec="test '${infra3Infrastructure}' == 'False'"/> - - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/prerequisites.xml b/framework/src/onos/tools/test/scenarios/prerequisites.xml deleted file mode 100644 index 5690fc4a..00000000 --- a/framework/src/onos/tools/test/scenarios/prerequisites.xml +++ /dev/null @@ -1,26 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="prerequisites" description="ONOS test pre-requisites"> - <group name="Prerequisites"> - <step name="Check-Environment" exec="test -n ${ONOS_ROOT} -a -n ${ONOS_NIC} -a -n ${OC1} -a '${ONOS_USE_SSH}' == 'true'"/> - <step name="Check-ONOS-Bits" exec="onos-check-bits"/> - - <parallel var="${OC#}"> - <step name="Check-Passwordless-Login-${#}" - exec="ssh -n -o ConnectTimeout=3 -o PasswordAuthentication=no ${ONOS_USER}@${OC#} date"/> - </parallel> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/sequential-example.xml b/framework/src/onos/tools/test/scenarios/sequential-example.xml deleted file mode 100644 index eee32d30..00000000 --- a/framework/src/onos/tools/test/scenarios/sequential-example.xml +++ /dev/null @@ -1,27 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="example" description="sequential scenario example"> - <group name="Wrapup"> - <!-- 'starts' is a comma-separated list of patterns that name steps starting the current iteration of the sequence --> - <!-- 'ends' is a comma-separated list of patterns that name steps ending the previous iteration of the sequence --> - <!-- In this example each Final-Check-Logs-(N) will become dependent on Fetch-Logs-(N-1), for N > 1 --> - <sequential var="${OC#}" starts="Final-Check-Logs-${#}" ends="Fetch-Logs-${#-1}"> - <step name="Final-Check-Logs-${#}" exec="onos-check-logs ${OC#}"/> - <step name="Fetch-Logs-${#}" exec="onos-fetch-logs ${OC#}" - cwd="${WORKSPACE}/tmp/stc" requires="~^"/> - </sequential> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/setup.xml b/framework/src/onos/tools/test/scenarios/setup.xml deleted file mode 100644 index 071db8b9..00000000 --- a/framework/src/onos/tools/test/scenarios/setup.xml +++ /dev/null @@ -1,47 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="setup" description="ONOS cluster setup"> - <group name="Setup"> - <step name="Push-Bits" exec="onos-push-bits-through-proxy" if="${OCT}"/> - <step name="Secure-SSH" exec="onos-secure-ssh -u ${ONOS_WEB_USER} -p ${ONOS_WEB_PASS}" if="${ONOS_USE_SSH}"/> - - <parallel var="${OC#}"> - <step name="Push-Bits-${#}" exec="onos-push-bits ${OC#}" - unless="${OCT}"/> - <step name="Uninstall-${#}" exec="onos-uninstall ${OC#}"/> - <step name="Kill-${#}" env="~" exec="onos-kill ${OC#}" - requires="Uninstall-${#}"/> - - <step name="Install-${#}" exec="onos-install ${OC#}" - requires="Kill-${#},Push-Bits-${#},Push-Bits"/> - - <dependency name="Secure-SSH" requires="Install-${#}"/> - - <step name="Wait-for-Start-${#}" exec="onos-wait-for-start ${OC#}" - requires="Install-${#},~Secure-SSH"/> - - <step name="Check-Nodes-${#}" exec="onos-check-nodes ${OC#}" - requires="~Wait-for-Start-${#}"/> - <step name="Check-Logs-${#}" exec="onos-check-logs ${OC#}" - requires="~Wait-for-Start-${#}"/> - <step name="Check-Components-${#}" - exec="onos-check-components ${OC#}" - requires="~Wait-for-Start-${#},"/> - <step name="Check-Apps-${#}" exec="onos-check-apps ${OC#} ${ONOS_APPS} includes" - requires="~Wait-for-Start-${#}"/> - </parallel> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/shutdown.xml b/framework/src/onos/tools/test/scenarios/shutdown.xml deleted file mode 100644 index 0be21647..00000000 --- a/framework/src/onos/tools/test/scenarios/shutdown.xml +++ /dev/null @@ -1,24 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="shutdown" description="ONOS cluster shutdown"> - <group name="Shutdown"> - <parallel var="${OC#}"> - <step name="Stop-Service-${#}" exec="onos-service ${OC#} stop"/> - <step name="Check-Logs-${#}" exec="onos-check-logs ${OC#}" - requires="~Stop-Service-${#}"/> - </parallel> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/smoke.xml b/framework/src/onos/tools/test/scenarios/smoke.xml deleted file mode 100644 index ce8140ad..00000000 --- a/framework/src/onos/tools/test/scenarios/smoke.xml +++ /dev/null @@ -1,30 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="smoke" description="ONOS smoke test"> - <import file="${ONOS_SCENARIOS}/prerequisites.xml"/> - - <import file="${ONOS_SCENARIOS}/setup.xml"/> - <dependency name="Setup" requires="Prerequisites"/> - - <import file="${ONOS_SCENARIOS}/net-smoke.xml"/> - <dependency name="Net-Smoke" requires="Setup"/> - - <import file="${ONOS_SCENARIOS}/archetypes.xml"/> - <dependency name="Archetypes" requires="Setup"/> - - <import file="${ONOS_SCENARIOS}/wrapup.xml"/> - <dependency name="Wrapup" requires="~Archetypes,~Setup,~Net-Smoke"/> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/startup.xml b/framework/src/onos/tools/test/scenarios/startup.xml deleted file mode 100644 index 430d51c3..00000000 --- a/framework/src/onos/tools/test/scenarios/startup.xml +++ /dev/null @@ -1,26 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="startup" description="ONOS cluster startup"> - <group name="Startup"> - <parallel var="${OC#}"> - <step name="Start-Service-${#}" exec="onos-service ${OC#} start"/> - <step name="Wait-for-Start-${#}" exec="onos-wait-for-start ${OC#}" - requires="Start-Service-${#}"/> - <step name="Check-Logs-${#}" exec="onos-check-logs ${OC#}" - requires="~Wait-for-Start-${#}"/> - </parallel> - </group> -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/tar-setup.xml b/framework/src/onos/tools/test/scenarios/tar-setup.xml deleted file mode 100644 index e330b2df..00000000 --- a/framework/src/onos/tools/test/scenarios/tar-setup.xml +++ /dev/null @@ -1,64 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="tar-setup" description="ONOS cluster setup via onos.tar.gz"> - <group name="Setup-Instances"> - <step name="Push-Bits" exec="onos-push-bits-through-proxy" if="${OCT}"/> - <step name="Secure-SSH" exec="onos-secure-ssh -u ${ONOS_WEB_USER} -p ${ONOS_WEB_PASS}" if="${ONOS_USE_SSH}"/> - - <parallel var="${OC#}"> - <step name="Push-Bits-${#}" exec="onos-push-bits ${OC#}" unless="${OCT}"/> - <step name="Uninstall-${#}" exec="onos-uninstall ${OC#}"/> - <step name="Kill-${#}" env="~" exec="onos-kill ${OC#}" requires="Uninstall-${#}"/> - - <step name="Untar-And-Run-${#}" exec="onos-untar-and-run ${OC#}" - requires="Kill-${#},Push-Bits-${#},Push-Bits"/> - - <dependency name="Secure-SSH" requires="Untar-And-Run-${#}"/> - - <step name="Wait-for-Start-${#}" exec="onos-wait-for-start ${OC#}" - requires="Untar-And-Run-${#},~Secure-SSH"/> - - <step name="Check-Logs-${#}" exec="onos-check-logs ${OC#}" - requires="~Wait-for-Start-${#}"/> - <step name="Check-Components-${#}" exec="onos-check-components ${OC#}" - requires="~Wait-for-Start-${#}"/> - <step name="Check-Apps-${#}" exec="onos-check-apps ${OC#} drivers" - requires="~Wait-for-Start-${#}"/> - - <step name="Check-Nodes-${#}" exec="onos-check-nodes ${OC#} ${OC#}" - requires="~Wait-for-Start-${#}"/> - </parallel> - </group> - - <group name="Setup-Cluster" requires="Setup-Instances" unless="${NO_CLUSTER}"> - <step name="Form-Cluster" exec="onos-form-cluster -u ${ONOS_WEB_USER} -p ${ONOS_WEB_PASS} cell"/> - <parallel var="${OC#}"> - <step name="Wait-for-Start-Again-${#}" exec="onos-wait-for-start ${OC#}" - requires="Form-Cluster"/> - - <step name="Check-Logs-Again-${#}" exec="onos-check-logs ${OC#}" - requires="~Wait-for-Start-Again-${#}"/> - <step name="Check-Components-Again-${#}" exec="onos-check-components ${OC#}" - requires="~Wait-for-Start-Again-${#}"/> - <step name="Check-Apps-Again-${#}" exec="onos-check-apps ${OC#} drivers" - requires="~Wait-for-Start-Again-${#}"/> - - <step name="Check-Nodes-Again-${#}" exec="onos-check-nodes ${OC#}" - requires="~Wait-for-Start-Again-${#}"/> - </parallel> - </group> - -</scenario> diff --git a/framework/src/onos/tools/test/scenarios/wrapup.xml b/framework/src/onos/tools/test/scenarios/wrapup.xml deleted file mode 100644 index e46441d6..00000000 --- a/framework/src/onos/tools/test/scenarios/wrapup.xml +++ /dev/null @@ -1,24 +0,0 @@ -<!-- - ~ Copyright 2015 Open Networking Laboratory - ~ - ~ Licensed under the Apache License, Version 2.0 (the "License"); - ~ you may not use this file except in compliance with the License. - ~ You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> -<scenario name="wrapup" description="ONOS test wrapup"> - <group name="Wrapup"> - <parallel var="${OC#}"> - <step name="Final-Check-Logs-${#}" exec="onos-check-logs ${OC#}"/> - <step name="Fetch-Logs-${#}" exec="onos-fetch-logs ${OC#}" - cwd="${WORKSPACE}/tmp/stc" requires="~^"/> - </parallel> - </group> -</scenario> |