Committed by
Gerrit Code Review
Add a scenario for multi point to single point intents
Change-Id: I0070c0baacb16d05f4cea42e904e417e478f944f
Showing
2 changed files
with
74 additions
and
1 deletions
| 1 | +<!-- | ||
| 2 | + ~ Copyright 2016 Open Networking Laboratory | ||
| 3 | + ~ | ||
| 4 | + ~ Licensed under the Apache License, Version 2.0 (the "License"); | ||
| 5 | + ~ you may not use this file except in compliance with the License. | ||
| 6 | + ~ You may obtain a copy of the License at | ||
| 7 | + ~ | ||
| 8 | + ~ http://www.apache.org/licenses/LICENSE-2.0 | ||
| 9 | + ~ | ||
| 10 | + ~ Unless required by applicable law or agreed to in writing, software | ||
| 11 | + ~ distributed under the License is distributed on an "AS IS" BASIS, | ||
| 12 | + ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| 13 | + ~ See the License for the specific language governing permissions and | ||
| 14 | + ~ limitations under the License. | ||
| 15 | + --> | ||
| 16 | +<scenario name="net-multi-to-single-intent" | ||
| 17 | + description="Network single point to multi point intent connectivity test"> | ||
| 18 | + <!-- TODO: parametrize this via recipes --> | ||
| 19 | + <group name="M2S-Intent-Connectivity"> | ||
| 20 | + <step name="M2S-Intent.Uninstall-Reactive-Forwarding" | ||
| 21 | + exec="onos ${OC1} app deactivate org.onosproject.fwd org.onosproject.ifwd"/> | ||
| 22 | + <step name="M2S-Intent.Check-Apps" requires="^" | ||
| 23 | + exec="onos-check-apps ${OC1} fwd,ifwd excludes"/> | ||
| 24 | + | ||
| 25 | + <!-- Create a single point to three points intent --> | ||
| 26 | + <step name="M2S-Intent.Create-Intent-forward" requires="^" | ||
| 27 | + exec="onos-create-intent ${OC1} forward multi-to-single of:0000000000000014/1 of:0000000000000002/1 of:000000000000000E/1 of:0000000000000011/1"/> | ||
| 28 | + | ||
| 29 | + <!-- Create back links from the 3 points back to the source using a single to multi intent --> | ||
| 30 | + <step name="M2S-Intent.Create-Intent-back" requires="^" | ||
| 31 | + exec="onos-create-intent ${OC1} back single-to-multi of:0000000000000011/1 of:0000000000000014/1 of:0000000000000002/1 of:000000000000000E/1"/> | ||
| 32 | + | ||
| 33 | + <!-- Make sure intents installed properly --> | ||
| 34 | + <step name="M2S-Intent.Validate-Intent-forward-Installed" requires="M2S-Intent.Create-Intent-forward" | ||
| 35 | + exec="onos-check-intent ${OC1} forward INSTALLED"/> | ||
| 36 | + <step name="M2S-Intent.Validate-Intent-back1-Installed" requires="M2S-Intent.Create-Intent-back1" | ||
| 37 | + exec="onos-check-intent ${OC1} back INSTALLED"/> | ||
| 38 | + | ||
| 39 | + <!-- Check the connectivity of the 11 <-> 14 intent --> | ||
| 40 | + <step name="M2S-Intent.Ping-1-forward" | ||
| 41 | + exec="onos-mininet sendAndExpect h17 ping -c1 h20 --expect \ 0% packet loss" requires="M2S-Intent.Create-Intent-forward, | ||
| 42 | + M2S-Intent.Create-Intent-back1" /> | ||
| 43 | + <step name="M2S-Intent.Ping-1-back" | ||
| 44 | + exec="onos-mininet sendAndExpect h20 ping -c1 h17 --expect \ 0% packet loss" requires="M2S-Intent.Create-Intent-forward, | ||
| 45 | + M2S-Intent.Create-Intent-back1" /> | ||
| 46 | + | ||
| 47 | + <!-- Check the connectivity of the 11 <-> 2 intent --> | ||
| 48 | + <step name="M2S-Intent.Ping-2-forward" | ||
| 49 | + exec="onos-mininet sendAndExpect h17 ping -c1 h2 --expect \ 0% packet loss" requires="M2S-Intent.Create-Intent-forward, | ||
| 50 | + M2S-Intent.Create-Intent-back1" /> | ||
| 51 | + <step name="M2S-Intent.Ping-2-back" | ||
| 52 | + exec="onos-mininet sendAndExpect h2 ping -c1 h17 --expect \ 0% packet loss" requires="M2S-Intent.Create-Intent-forward, | ||
| 53 | + M2S-Intent.Create-Intent-back1" /> | ||
| 54 | + | ||
| 55 | + <!-- Check the connectivity of the 11 <-> E intent --> | ||
| 56 | + <step name="M2S-Intent.Ping-3-forward" | ||
| 57 | + exec="onos-mininet sendAndExpect h17 ping -c1 h14 --expect \ 0% packet loss" requires="M2S-Intent.Create-Intent-forward, | ||
| 58 | + M2S-Intent.Create-Intent-back2" /> | ||
| 59 | + <step name="M2S-Intent.Ping-3-back" | ||
| 60 | + exec="onos-mininet sendAndExpect h14 ping -c1 h17 --expect \ 0% packet loss" requires="M2S-Intent.Create-Intent-forward, | ||
| 61 | + M2S-Intent.Create-Intent-back3" /> | ||
| 62 | + | ||
| 63 | + <!-- Clean up intents --> | ||
| 64 | + <step name="M2S-Intent.Remove-Intent-forward" requires="~M2S-Intent.Ping-3-back" | ||
| 65 | + exec="onos ${OC1} remove-intent -p org.onosproject.cli forward"/> | ||
| 66 | + <step name="M2S-Intent.Remove-Intent-back" requires="~M2S-Intent.Ping-3-back" | ||
| 67 | + exec="onos ${OC1} remove-intent -p org.onosproject.cli back"/> | ||
| 68 | + </group> | ||
| 69 | +</scenario> |
| ... | @@ -33,8 +33,12 @@ | ... | @@ -33,8 +33,12 @@ |
| 33 | <dependency name="S2M-Intent-Connectivity" | 33 | <dependency name="S2M-Intent-Connectivity" |
| 34 | requires="Net-Setup,~Reactive-Forwarding.Net-Link-Down-Up,Host-Intent-Connectivity,P2P-Intent-Connectivity"/> | 34 | requires="Net-Setup,~Reactive-Forwarding.Net-Link-Down-Up,Host-Intent-Connectivity,P2P-Intent-Connectivity"/> |
| 35 | 35 | ||
| 36 | + <import file="${ONOS_SCENARIOS}/net-multi-to-single-intent.xml"/> | ||
| 37 | + <dependency name="M2S-Intent-Connectivity" | ||
| 38 | + requires="S2M-Intent-Connectivity"/> | ||
| 39 | + | ||
| 36 | <import file="${ONOS_SCENARIOS}/net-rest.xml"/> | 40 | <import file="${ONOS_SCENARIOS}/net-rest.xml"/> |
| 37 | - <dependency name="Net-REST" requires="Net-Setup,P2P-Intent-Connectivity,S2M-Intent-Connectivity"/> | 41 | + <dependency name="Net-REST" requires="Net-Setup,P2P-Intent-Connectivity,M2S-Intent-Connectivity"/> |
| 38 | 42 | ||
| 39 | <import file="${ONOS_SCENARIOS}/net-create-flows.xml"/> | 43 | <import file="${ONOS_SCENARIOS}/net-create-flows.xml"/> |
| 40 | <dependency name="Net-Create-Flows" requires="Net-Setup,P2P-Intent-Connectivity,Net-REST"/> | 44 | <dependency name="Net-Create-Flows" requires="Net-Setup,P2P-Intent-Connectivity,Net-REST"/> | ... | ... |
-
Please register or login to post a comment