CSIT-576 HC Test: Improve SPAN test coverage
[csit.git] / resources / libraries / robot / honeycomb / netconf.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 *** Settings ***
15 | Library | resources.libraries.python.honeycomb.Netconf
16 | Variables | resources/test_data/honeycomb/netconf/hello.py
17 | Documentation | Keywords for managing Netconf communication.
18
19 *** Keywords ***
20 | Netconf session is established
21 | | [Documentation] | Open a communication channel on the Netconf session\
22 | | ... | and exchange hello messages.
23 | | ...
24 | | ... | *Arguments:*
25 | | ... | - node - information about a DUT node. Type: dict
26 | | ...
27 | | ... | *Example:*
28 | | ...
29 | | ... | \| Netconf session is established \| ${nodes['DUT1']} \|
30 | | [Arguments] | ${node}
31 | | Create session | ${node} | ${hello}
32
33 | Error trigger is sent
34 | | [Documentation] | Send the specified error trigger through the channel.
35 | | ...
36 | | ... | *Arguments:*
37 | | ... | - trigger - RPC sequence that triggers a specific error. Type: string
38 | | ... | - params - Parameters for the trigger template. Type: string
39 | | ...
40 | | ... | *Example:*
41 | | ...
42 | | ... | \| Error trigger is sent \| <rpc>_some data_</rpc>]]>]]> \|
43 | | [Arguments] | ${trigger} | &{params}
44 | | Send | ${trigger} | &{params}
45
46 | Replies should not contain RPC errors
47 | | [Documentation] | Read response received through the channel, and check if\
48 | | ... | it is an error report.
49 | | ...
50 | | ... | *Arguments:*
51 | | ... | none
52 | | ...
53 | | ... | *Example:*
54 | | ...
55 | | ... | \| Replies should not contain RPC errors \|
56 | | ${resp}= | Get all responses
57 | | should not contain | ${resp} | rpc-error