meta-apps-test.xml
6.38 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
<!--
~ Copyright 2016-present 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="meta-apps"
description="Openflow provider activate/deactivate test">
<group name="Meta-App">
<!-- Check initial state of openflow apps -->
<group name="MetaAppInitialVerification">
<parallel var="${OC#}" starts="MetaAppTest.FindOpenflowInitial-${#}" ends="MetaAppTest.CheckLldpProviderInitial-${#-1}">
<step name="MetaAppTest.FindOpenflowInitial-${#}"
exec="onos-find-app ${OC#} org.onosproject.openflow openflowAppInitial" />
<step name="MetaAppTest.CheckOpenflowInitial-${#}" requires="MetaAppTest.FindOpenflowInitial-${#}"
exec="test '${openflowAppInitialState}' == 'active'"/>
<step name="MetaAppTest.FindOpenflowBaseInitial-${#}"
exec="onos-find-app ${OC#} org.onosproject.openflow-base openflowBaseInitial" />
<step name="MetaAppTest.CheckOpenflowBaseInitial-${#}" requires="MetaAppTest.FindOpenflowBaseInitial-${#}"
exec="test '${openflowBaseInitialState}' == 'active'"/>
<step name="MetaAppTest.FindHostProviderInitial-${#}"
exec="onos-find-app ${OC#} org.onosproject.hostprovider hostProviderInitial" />
<step name="MetaAppTest.CheckHostProviderInitial-${#}" requires="MetaAppTest.FindHostProviderInitial-${#}"
exec="test '${hostProviderInitialState}' == 'active'"/>
<step name="MetaAppTest.FindLldpProviderInitial-${#}"
exec="onos-find-app ${OC#} org.onosproject.lldpprovider lldpProviderInitial" />
<step name="MetaAppTest.CheckLldpProviderInitial-${#}" requires="MetaAppTest.FindLldpProviderInitial-${#}"
exec="test '${lldpProviderInitialState}' == 'active'"/>
</parallel>
</group>
<!-- Deactivate openflow meta app -->
<step name="MetaAppTest.DeactivateOpenflowMetaApp" requires="MetaAppInitialVerification"
exec="onos ${OCI} onos:app deactivate org.onosproject.openflow"/>
<!-- Check that openflow apps are no longer active -->
<group name="MetaAppInactive" requires="MetaAppTest.DeactivateOpenflowMetaApp,MetaAppInitialVerification">
<parallel var="${OC#}" starts="MetaAppTest.FindOpenflowInactive-${#}" ends="MetaAppTest.CheckLldpProviderInactive-${#-1}">
<step name="MetaAppTest.FindOpenflowInactive-${#}"
exec="onos-find-app ${OC#} org.onosproject.openflow openflowAppInactive" />
<step name="MetaAppTest.CheckOpenflowInactive-${#}" requires="^"
exec="test '${openflowAppInactiveState}' == 'inactive'"/>
<step name="MetaAppTest.FindOpenflowBaseInactive-${#}" requires="^"
exec="onos-find-app ${OC#} org.onosproject.openflow-base openflowBaseInactive" />
<step name="MetaAppTest.CheckOpenflowBaseInactive-${#}" requires="^"
exec="test '${openflowBaseInactiveState}' == 'inactive'"/>
<step name="MetaAppTest.FindHostProviderInactive-${#}" requires="^"
exec="onos-find-app ${OC#} org.onosproject.hostprovider hostProviderInactive" />
<step name="MetaAppTest.CheckHostProviderInactive-${#}" requires="^"
exec="test '${hostProviderInactiveState}' == 'inactive'"/>
<step name="MetaAppTest.FindLldpProviderInactive-${#}" requires="^"
exec="onos-find-app ${OC#} org.onosproject.lldpprovider lldpProviderInactive" />
<step name="MetaAppTest.CheckLldpProviderInactive-${#}" requires="^"
exec="test '${lldpProviderInactiveState}' == 'inactive'"/>
</parallel>
</group>
<!-- Reactivate openflow meta app -->
<step name="MetaAppTest.ReactivateOpenflowMetaApp" requires="MetaAppInactive"
exec="onos ${OCI} onos:app activate org.onosproject.openflow"/>
<!-- Check that openflow apps are now active again -->
<group name="MetaAppReactivated" requires="MetaAppTest.ReactivateOpenflowMetaApp,MetaAppInactive,MetaAppInitialVerification">
<parallel var="${OC#}" starts="MetaAppTest.FindOpenflowReactivated-${#}" ends="MetaAppTest.CheckLldpProviderRectivated-${#-1}">
<step name="MetaAppTest.FindOpenflowReactivated-${#}"
exec="onos-find-app ${OC#} org.onosproject.openflow openflowAppReactivated" />
<step name="MetaAppTest.CheckOpenflowReactivated-${#}" requires="^"
exec="test '${openflowAppReactivatedState}' == 'active'"/>
<step name="MetaAppTest.FindOpenflowBaseReactivated-${#}" requires="^"
exec="onos-find-app ${OC#} org.onosproject.openflow-base openflowBaseReactivated" />
<step name="MetaAppTest.CheckOpenflowBaseReactivated-${#}" requires="^"
exec="test '${openflowBaseReactivatedState}' == 'active'"/>
<step name="MetaAppTest.FindHostProviderReactivated-${#}" requires="^"
exec="onos-find-app ${OC#} org.onosproject.hostprovider hostProviderReactivated" />
<step name="MetaAppTest.CheckHostProviderReactivated-${#}" requires="^"
exec="test '${hostProviderReactivatedState}' == 'active'"/>
<step name="MetaAppTest.FindLldpProviderReactivated-${#}" requires="^"
exec="onos-find-app ${OC#} org.onosproject.lldpprovider lldpProviderReactivated" />
<step name="MetaAppTest.CheckLldpProviderReactivated-${#}" requires="^"
exec="test '${lldpProviderReactivatedState}' == 'active'"/>
</parallel>
</group>
</group>
</scenario>