2 Documentation Test suite to verify fitration operation on different models.
3 ... Before test starts, configurational file have to be rewriten to change listners registration datastore type from CONFIGURATION to OPERATIONAL.
4 ... Need for this change is also a reason why main feature (odl-topoprocessing-framework) is installed after file change and not during boot.
5 ... Tests themselves install feature required for specific model, clear karaf logs for futher synchronization, send configurational xmls and verify output.
6 ... Topology-id on the end of each urls must match topology-id from xml. Yang models of components in topology are defined in xmls.
8 Library RequestsLibrary
11 Variables ../../../variables/topoprocessing/TopologyRequests.py
12 Variables ../../../variables/topoprocessing/TargetFields.py
13 Variables ../../../variables/Variables.py
14 Resource ../../../libraries/KarafKeywords.robot
15 Resource ../../../libraries/Utils.robot
16 Resource ../../../libraries/TopoprocessingKeywords.robot
18 Suite Setup Setup Environment
19 Suite Teardown Clean Environment
20 Test Setup SetupUtils.Setup_Test_With_Logging_And_Without_Fast_Failing
21 Test Teardown Delete Overlay Topology
25 Filtration Range Number Network Topology Model
26 [Documentation] Test of range number type of filtration operation on Network Topology model
27 ${request} Prepare Filtration Topology Request
29 ... network-topology-model
32 ${request} Insert Filter ${request} ${FILTER_RANGE_NUMBER} ${IGP_LINK_METRIC}
33 ${request} Set Range Number Filter ${request} 11 13
34 Basic Request Put ${request} ${OVERLAY_TOPO_URL}
35 ${resp} Wait Until Keyword Succeeds
38 ... Output Topo Should Be Complete
41 Check Filtered Links In Topology ${resp.content} link:1:2-1 link:1:3 link:1:4
43 Filtration Range Number Inventory Model
44 [Documentation] Test of range number type of filtration operation on Inventory model
45 ${request} Prepare Filtration Topology Request
47 ... opendaylight-inventory-model
50 ${request} Insert Filter ${request} ${FILTER_RANGE_NUMBER} ${IGP_LINK_METRIC}
51 ${request} Set Range Number Filter ${request} 14 15
52 Basic Request Put ${request} ${OVERLAY_TOPO_URL}
53 ${resp} Wait Until Keyword Succeeds
56 ... Output Topo Should Be Complete
59 Check Filtered Links In Topology ${resp.content} link:14:12 link:15:13
61 Filtration Specific String Network Topology Model
62 [Documentation] Test of specific string type of filtration operation on Network Topology model
63 ${request} Prepare Filtration Topology Request
65 ... network-topology-model
68 ${request} Insert Filter ${request} ${FILTER_SPECIFIC_STRING} ${IGP_LINK_NAME}
69 ${request} Set Specific String Filter ${request} linkA
70 Basic Request Put ${request} ${OVERLAY_TOPO_URL}
71 ${resp} Wait Until Keyword Succeeds
74 ... Output Topo Should Be Complete
77 Check Filtered Links In Topology ${resp.content} link:1:4 link:1:2-1
79 Filtration Specific String Inventory Model
80 [Documentation] Test of specific string type of filtration operation on Inventory model
81 ${request} Prepare Filtration Topology Request
83 ... opendaylight-inventory-model
86 ${request} Insert Filter ${request} ${FILTER_SPECIFIC_STRING} ${IGP_LINK_NAME}
87 ${request} Set Specific String Filter ${request} linkD
88 Basic Request Put ${request} ${OVERLAY_TOPO_URL}
89 ${resp} Wait Until Keyword Succeeds
92 ... Output Topo Should Be Complete
95 Check Filtered Links In Topology ${resp.content} link:15:13
97 Filtration Range String Network Topology Model
98 [Documentation] Test of range string type of filtration operation on Network Topology model
99 ${request} Prepare Filtration Topology Request
101 ... network-topology-model
104 ${request} Insert Filter ${request} ${FILTER_RANGE_STRING} ${IGP_LINK_NAME}
105 ${request} Set Range String Filter ${request} linkA linkB
106 Basic Request Put ${request} ${OVERLAY_TOPO_URL}
107 ${resp} Wait Until Keyword Succeeds
110 ... Output Topo Should Be Complete
113 Check Filtered Links In Topology ${resp.content} link:1:2-1 link:1:3 link:1:4
115 Filtration Range String Inventory Model
116 [Documentation] Test of range string type of filtration operation on Inventory model
117 ${request} Prepare Filtration Topology Request
119 ... opendaylight-inventory-model
122 ${request} Insert Filter ${request} ${FILTER_RANGE_STRING} ${IGP_LINK_NAME}
123 ${request} Set Range String Filter ${request} linkC linkD
124 Basic Request Put ${request} ${OVERLAY_TOPO_URL}
125 ${resp} Wait Until Keyword Succeeds
128 ... Output Topo Should Be Complete
131 Check Filtered Links In Topology ${resp.content} link:14:12 link:15:13
133 Filtration Script Network Topology Model
134 [Documentation] Test of script type of filtration operation on Network Topology model
135 ${request} Prepare Filtration Topology Request
137 ... network-topology-model
140 ${request} Insert Filter ${request} ${FILTER_SCRIPT} ${IGP_LINK_NAME}
141 ${script} Set Variable
142 ... if (node.getValue().indexOf("linkA") > -1 ) {filterOut.setResult(true);} else {filterOut.setResult(false);}
143 ${request} Set Script Filter ${request} javascript ${script}
144 Basic Request Put ${request} ${OVERLAY_TOPO_URL}
145 ${resp} Wait Until Keyword Succeeds
148 ... Output Topo Should Be Complete
151 Check Filtered Links In Topology ${resp.content} link:1:2-2 link:1:3
153 Filtration Script Inventory Model
154 [Documentation] Test of script type of filtration operation on Inventory model
155 ${request} Prepare Filtration Topology Request
157 ... opendaylight-inventory-model
160 ${request} Insert Filter ${request} ${FILTER_SCRIPT} ${IGP_LINK_NAME}
161 ${script} Set Variable
162 ... if (node.getValue().indexOf("linkA") > -1 ) {filterOut.setResult(true);} else {filterOut.setResult(false);}
163 ${request} Set Script Filter ${request} javascript ${script}
164 Basic Request Put ${request} ${OVERLAY_TOPO_URL}
165 ${resp} Wait Until Keyword Succeeds
168 ... Output Topo Should Be Complete
171 Check Filtered Links In Topology ${resp.content} link:11:12 link:14:12 link:15:13