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:
6 # http://www.apache.org/licenses/LICENSE-2.0
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.
15 | Library | resources.libraries.python.honeycomb.HcAPIKwInterfaces.InterfaceKeywords
16 | ... | WITH NAME | IfAPI
19 | Honeycomb creates PBB sub-interface
20 | | [Documentation] | Uses Honeycomb API to set PBB sub-interface on an\
23 | | ... | *Arguments:*
24 | | ... | - node - Information about a DUT node. Type: dictionary
25 | | ... | - super_if - Super-interface. Type: string
26 | | ... | - sub_if_id - Sub-interface ID. Type: string
27 | | ... | - params - Parameters of the sub-interface to be created.
28 | | ... | Type - dictionary
31 | | ... | \| Honeycomb creates PBB sub-interface \| ${node} \| ${super_if}\
32 | | ... | \| ${cfg_pbb_sub_if_1} \|
34 | | [Arguments] | ${node} | ${super_if} | ${params}
36 | | IfAPI.Set Interface Up | ${node} | ${super_if}
37 | | IfAPI.Create PBB Sub Interface
38 | | ... | ${node} | ${super_if} | ${params}
40 | Honeycomb removes PBB sub-interface
41 | | [Documentation] | Uses Honeycomb API to remove PBB sub-interface from its\
42 | | ... | super interface.
44 | | ... | *Arguments:*
45 | | ... | - node - Information about a DUT node. Type: dictionary
46 | | ... | - super_if - Super-interface. Type: string
47 | | ... | - sub_if_id - Sub-interface ID. Type: string
50 | | ... | \| Honeycomb removes PBB sub-interface\
51 | | ... | \| ${node} \| ${super_if} \|
53 | | [Arguments] | ${node} | ${super_if}
55 | | Delete PBB Sub Interface | ${node} | ${super_if}
57 | Honeycomb fails to create PBB sub-interface
58 | | [Documentation] | Uses Honeycomb API to set PBB sub-interface with wrong\
59 | | ... | parameter(s) and expects to fail.
61 | | ... | *Arguments:*
62 | | ... | - node - Information about a DUT node. Type: dictionary
63 | | ... | - super_if - Super-interface. Type: string
64 | | ... | - sub_if_id - Sub-interface ID. Type: string
65 | | ... | - params - Parameters of the sub-interface to be created.
66 | | ... | Type - dictionary
69 | | ... | \| Honeycomb fails to create PBB sub-interface\
70 | | ... | \| ${node} \| ${super_if} \| ${cfg_pbb_sub_if_no_vlan_tag} \|
72 | | [Arguments] | ${node} | ${super_if} | ${params}
74 | | IfAPI.Set Interface Up | ${node} | ${super_if}
75 | | Run keyword and expect error | *HoneycombError*not successful*.
76 | | ... | IfAPI.Create PBB Sub Interface
77 | | ... | ${node} | ${super_if} | ${params}