CSIT-576 HC Test: Improve SPAN test coverage
[csit.git] / tests / func / honeycomb / mgmt-cfg-intvhost-apihc-apivat-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}= | ${node['interfaces']['port1']['name']}
16 | ${vhost_interface}= | test_vhost
17 | &{vhost_user_server}= | socket=/tmp/soc1 | role=server
18 | &{vhost_user_server_edit_1}= | socket=/tmp/soc12 | role=server
19 | &{vhost_user_server_edit_2}= | socket=/tmp/soc12 | role=client
20 | &{vhost_user_client}= | socket=/tmp/soc2 | role=client
21 | &{vhost_user_client_edit_1}= | socket=/tmp/soc22 | role=client
22 | &{vhost_user_client_edit_2}= | socket=/tmp/soc22 | role=server
23 | &{vhost_user_wrong}= | socket=/tmp/soc2 | role=wrong
24
25 *** Settings ***
26 | Resource | resources/libraries/robot/default.robot
27 | Resource | resources/libraries/robot/honeycomb/honeycomb.robot
28 | Resource | resources/libraries/robot/honeycomb/vhost_user.robot
29 | Force Tags | HC_FUNC
30 | Suite Teardown | Run Keyword If Any Tests Failed
31 | ... | Restart Honeycomb and VPP | ${node}
32 | Documentation | *Honeycomb vhost-user interface management test suite.*
33
34 *** Test Cases ***
35 | TC01: Honeycomb creates vhost-user interface - server
36 | | [Documentation] | Check if Honeycomb creates a vhost-user interface, role:\
37 | | ... | server.
38 | | ...
39 | | Given vhost-user Operational Data From Honeycomb Should Be empty
40 | | ... | ${node} | ${vhost_interface}
41 | | When Honeycomb creates vhost-user interface
42 | | ... | ${node} | ${vhost_interface} | ${vhost_user_server}
43 | | Then vhost-user Operational Data From Honeycomb Should Be
44 | | ... | ${node} | ${vhost_interface} | ${vhost_user_server}
45 | | And vhost-user Operational Data From VAT Should Be
46 | | ... | ${node} | ${vhost_user_server}
47
48 | TC02: Honeycomb modifies vhost-user interface - server
49 | | [Documentation] | Check if Honeycomb can modify properties of existing\
50 | | ... | vhost-user interface, role: server.
51 | | ...
52 | | Given vhost-user Operational Data From Honeycomb Should Be
53 | | ... | ${node} | ${vhost_interface} | ${vhost_user_server}
54 | | When Honeycomb configures vhost-user interface
55 | | ... | ${node} | ${vhost_interface} | ${vhost_user_server_edit_1}
56 | | Then vhost-user Operational Data From Honeycomb Should Be
57 | | ... | ${node} | ${vhost_interface} | ${vhost_user_server_edit_1}
58 | | And vhost-user Operational Data From VAT Should Be
59 | | ... | ${node} | ${vhost_user_server_edit_1}
60 | | When Honeycomb configures vhost-user interface
61 | | ... | ${node} | ${vhost_interface} | ${vhost_user_server_edit_2}
62 | | Then vhost-user Operational Data From Honeycomb Should Be
63 | | ... | ${node} | ${vhost_interface} | ${vhost_user_server_edit_2}
64 | | And vhost-user Operational Data From VAT Should Be
65 | | ... | ${node} | ${vhost_user_server_edit_2}
66 | | When Honeycomb configures vhost-user interface
67 | | ... | ${node} | ${vhost_interface} | ${vhost_user_server}
68 | | Then vhost-user Operational Data From Honeycomb Should Be
69 | | ... | ${node} | ${vhost_interface} | ${vhost_user_server}
70 | | And vhost-user Operational Data From VAT Should Be
71 | | ... | ${node} | ${vhost_user_server}
72
73 | TC03: Honeycomb deletes vhost-user interface - server
74 | | [Documentation] | Check if Honeycomb can delete an existing vhost-user\
75 | | ... | interface, role: server.
76 | | ...
77 | | Given vhost-user Operational Data From Honeycomb Should Be
78 | | ... | ${node} | ${vhost_interface} | ${vhost_user_server}
79 | | When Honeycomb removes vhost-user interface
80 | | ... | ${node} | ${vhost_interface}
81 | | Then vhost-user Operational Data From Honeycomb Should Be empty
82 | | ... | ${node} | ${vhost_interface}
83 | | And vhost-user Operational Data From VAT Should Be empty
84 | | ... | ${node}
85
86 | TC04: Honeycomb creates vhost-user interface - client
87 | | [Documentation] | Check if Honeycomb creates a vhost-user interface, role:\
88 | | ... | client.
89 | | ...
90 | | Given vhost-user Operational Data From Honeycomb Should Be empty
91 | | ... | ${node} | ${vhost_interface}
92 | | When Honeycomb creates vhost-user interface
93 | | ... | ${node} | ${vhost_interface} | ${vhost_user_client}
94 | | Then vhost-user Operational Data From Honeycomb Should Be
95 | | ... | ${node} | ${vhost_interface} | ${vhost_user_client}
96 | | And vhost-user Operational Data From VAT Should Be
97 | | ... | ${node} | ${vhost_user_client}
98
99 | TC05: Honeycomb modifies vhost-user interface - client
100 | | [Documentation] | Check if Honeycomb can modify properties of existing\
101 | | ... | vhost-user interface, role: client.
102 | | ...
103 | | Given vhost-user Operational Data From Honeycomb Should Be
104 | | ... | ${node} | ${vhost_interface} | ${vhost_user_client}
105 | | When Honeycomb configures vhost-user interface
106 | | ... | ${node} | ${vhost_interface} | ${vhost_user_client_edit_1}
107 | | Then vhost-user Operational Data From Honeycomb Should Be
108 | | ... | ${node} | ${vhost_interface} | ${vhost_user_client_edit_1}
109 | | And vhost-user Operational Data From VAT Should Be
110 | | ... | ${node} | ${vhost_user_client_edit_1}
111 | | When Honeycomb configures vhost-user interface
112 | | ... | ${node} | ${vhost_interface} | ${vhost_user_client_edit_2}
113 | | Then vhost-user Operational Data From Honeycomb Should Be
114 | | ... | ${node} | ${vhost_interface} | ${vhost_user_client_edit_2}
115 | | And vhost-user Operational Data From VAT Should Be
116 | | ... | ${node} | ${vhost_user_client_edit_2}
117 | | When Honeycomb configures vhost-user interface
118 | | ... | ${node} | ${vhost_interface} | ${vhost_user_client}
119 | | Then vhost-user Operational Data From Honeycomb Should Be
120 | | ... | ${node} | ${vhost_interface} | ${vhost_user_client}
121 | | And vhost-user Operational Data From VAT Should Be
122 | | ... | ${node} | ${vhost_user_client}
123
124 | TC06: Honeycomb deletes vhost-user interface - client
125 | | [Documentation] | Check if Honeycomb can delete an existing vhost-user\
126 | | ... | interface, role: client.
127 | | ...
128 | | Given vhost-user Operational Data From Honeycomb Should Be
129 | | ... | ${node} | ${vhost_interface} | ${vhost_user_client}
130 | | When Honeycomb removes vhost-user interface
131 | | ... | ${node} | ${vhost_interface}
132 | | Then vhost-user Operational Data From Honeycomb Should Be empty
133 | | ... | ${node} | ${vhost_interface}
134 | | And vhost-user Operational Data From VAT Should Be empty
135 | | ... | ${node}
136
137 | TC07: Honeycomb does not set vhost-user configuration on another interface type
138 | | [Documentation] | Check if Honeycomb refuses to set vhost-user\
139 | | ... | configuration for interface which is not v3po:vhost-user type.
140 | | ...
141 | | When Honeycomb fails setting vhost-user on different interface type
142 | | ... | ${node} | ${interface} | ${vhost_user_server}
143 | | Then vhost-user Operational Data From Honeycomb Should Be empty
144 | | ... | ${node} | ${interface}
145 | | And vhost-user Operational Data From VAT Should Be empty
146 | | ... | ${node}
147
148 | TC08: Honeycomb does not set invalid vhost-user configuration
149 | | [Documentation] | Check if Honeycomb refuses to set invalid parameters to\
150 | | ... | vhost-user interface.
151 | | ...
152 | | Given vhost-user Operational Data From Honeycomb Should Be empty
153 | | ... | ${node} | ${vhost_interface}
154 | | When Honeycomb fails setting invalid vhost-user configuration
155 | | ... | ${node} | ${vhost_interface} | ${vhost_user_wrong}
156 | | Then vhost-user Operational Data From Honeycomb Should Be empty
157 | | ... | ${node} | ${vhost_interface}
158 | | And vhost-user Operational Data From VAT Should Be empty
159 | | ... | ${node}