90ed077533492b819e8ff39ab7e734a6a1fd8ac8
[csit.git] / tests / func / honeycomb / mgmt-statepersist-apihc-func.robot
1 # Copyright (c) 2016 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
5 #
6 #     http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
13
14 *** Variables***
15 # Interface to run tests on.
16 | ${interface}= | ${node['interfaces']['port1']['name']}
17
18 *** Settings ***
19 | Resource | resources/libraries/robot/default.robot
20 | Resource | resources/libraries/robot/honeycomb/persistence.robot
21 | Resource | resources/libraries/robot/honeycomb/interfaces.robot
22 | Resource | resources/libraries/robot/honeycomb/bridge_domain.robot
23 | Resource | resources/libraries/robot/honeycomb/l2_fib.robot
24 | ...
25 | Suite Setup | Run Keywords
26 | ... | Configure Persistence | ${node} | enable | AND
27 | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
28 | ...
29 | Suite Teardown | Configure Persistence | ${node} | disable
30 | ...
31 | Force Tags | HC_PERSIST | HC_REST_ONLY
32 | ...
33 | Documentation | *Honeycomb configuration persistence test suite.*
34
35 *** Test Cases ***
36 # multi-feature cases
37 # ===================
38 | TC01: Honeycomb persists configuration through restart of both Honeycomb and VPP
39 | | [Documentation] | Checks if Honeycomb maintains configuration after both\
40 | | ... | Restart Honeycomb and VPP.
41 | | ...
42 | | [Tags] | HC_FUNC
43 | | ...
44 | | [Teardown]
45 | | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
46 | | ...
47 | | Given Multi-Feature Persistence test configuration | ${node} | ${interface}
48 | | And Multi-Feature persistence Test Verification | ${node} | ${interface}
49 | | And Log persisted configuration on node | ${node}
50 | | When Restart Honeycomb and VPP in pesistence test | ${node}
51 | | Then Multi-Feature persistence Test Verification | ${node} | ${interface}
52
53 | TC02: Honeycomb reverts to defaults if persistence files are invalid
54 | | [Documentation] | Checks if Honeycomb reverts to default configuration when\
55 | | ... | persistence files are damaged or invalid.
56 | | ...
57 | | [Tags] | HC_FUNC
58 | | ...
59 | | [Teardown]
60 | | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
61 | | ...
62 | | Given Multi-Feature Persistence test configuration | ${node} | ${interface}
63 | | And Multi-Feature persistence Test Verification | ${node} | ${interface}
64 | | When Persistence file is damaged during restart | ${node}
65 | | Then Honeycomb and VPP should have default configuration | ${node}
66
67 | TC03: Honeycomb persists configuration through restart of Honeycomb
68 | | [Documentation] | Checks if Honeycomb maintains configuration after it\
69 | | ... | is restarted.
70 | | ...
71 | | [Teardown]
72 | | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
73 | | ...
74 | | Given Multi-Feature Persistence test configuration | ${node} | ${interface}
75 | | And Multi-Feature persistence Test Verification | ${node} | ${interface}
76 | | And Log persisted configuration on node | ${node}
77 | | When Restart Honeycomb | ${node}
78 | | Then Multi-Feature persistence Test Verification | ${node} | ${interface}
79
80 | TC04: Honeycomb persists configuration through restart of VPP
81 | | [Documentation] | Checks if Honeycomb updates VPP settings after VPP is\
82 | | ... | restarted.
83 | | ...
84 | | [Teardown]
85 | | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
86 | | ...
87 | | Given Multi-Feature Persistence test configuration | ${node} | ${interface}
88 | | And Multi-Feature persistence Test Verification | ${node} | ${interface}
89 | | And Log persisted configuration on node | ${node}
90 | | When Restart VPP | ${node}
91 | | Then Multi-Feature persistence Test Verification | ${node} | ${interface}
92
93 # single-feature cases
94 # ====================
95
96 | TC05: Persist configuration of IP addresses and neighbors - HC and VPP restart
97 | | [Documentation] | Verify persistence of interface state, IPv4 address
98 | | ... | and neighbor entries through restart of both Honeycomb and VPP.
99 | | ...
100 | | [Teardown]
101 | | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
102 | | ...
103 | | Given Interface Persistence Setup | ${node}
104 | | And Interface Persistence Check | ${node}
105 | | When Restart Honeycomb and VPP in pesistence test | ${node}
106 | | Then Interface Persistence Check | ${node}
107
108 | TC06: Persist configuration of IP addresses and neighbors - HC restart
109 | | [Documentation] | Verify persistence of interface state, IPv4 address
110 | | ... | and neighbor entries through restart of Honeycomb.
111 | | ...
112 | | [Teardown]
113 | | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
114 | | ...
115 | | Given Interface Persistence Setup | ${node}
116 | | And Interface Persistence Check | ${node}
117 | | When Restart Honeycomb | ${node}
118 | | Then Interface Persistence Check | ${node}
119
120 | TC07: Persist configuration of IP addresses and neighbors - VPP restart
121 | | [Documentation] | Verify persistence of interface state, IPv4 address
122 | | ... | and neighbor entries through restart of VPP.
123 | | ...
124 | | [Teardown]
125 | | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
126 | | ...
127 | | Given Interface Persistence Setup | ${node}
128 | | And Interface Persistence Check | ${node}
129 | | When Restart VPP | ${node}
130 | | Then Interface Persistence Check | ${node}
131
132 | TC08: Honeycomb persists configuration of bridge domains - HC and VPP restart
133 | | [Documentation] | Verify persistence of bridge domain, L2-FIB entry
134 | | ... | and Bridge domain Operational Interface Assignment through restart
135 | | ... | of both Honeycomb and VPP.
136 | | ...
137 | | [Teardown]
138 | | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
139 | | ...
140 | | Given Bridge Domain Persistence Setup | ${node}
141 | | When Restart Honeycomb and VPP in pesistence test | ${node}
142 | | Then Bridge Domain Persistence Check | ${node}
143
144 | TC09: Honeycomb persists configuration of bridge domains - HC restart
145 | | [Documentation] | Verify persistence of bridge domain, L2-FIB entry
146 | | ... | and Bridge domain Operational Interface Assignment through restart
147 | | ... | of Honeycomb.
148 | | ...
149 | | [Teardown]
150 | | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
151 | | ...
152 | | Given Bridge Domain Persistence Setup | ${node}
153 | | When Restart Honeycomb | ${node}
154 | | Then Bridge Domain Persistence Check | ${node}
155
156 | TC10: Honeycomb persists configuration of bridge domains - VPP restart
157 | | [Documentation] | Verify persistence of bridge domain, L2-FIB entry
158 | | ... | and Bridge domain Operational Interface Assignment through restart
159 | | ... | of VPP.
160 | | ...
161 | | [Teardown]
162 | | ... | Restart Honeycomb And VPP And Clear Persisted Configuration | ${node}
163 | | ...
164 | | Given Bridge Domain Persistence Setup | ${node}
165 | | When Restart VPP | ${node}
166 | | Then Bridge Domain Persistence Check | ${node}
167
168 #TODO: All other features