2 Documentation Test suite for the statistics manager module
3 Suite Setup Create Session session http://${CONTROLLER}:8080 auth=${AUTH} headers=${HEADERS}
4 Suite Teardown Delete All Sessions
6 Library ../../libraries/RequestsLibrary.py
7 Library ../../libraries/Common.py
8 Variables ../../variables/Variables.py
11 ${node1} "node":{"type":"OF","id":"00:00:00:00:00:00:00:01"}
12 ${node2} "node":{"type":"OF","id":"00:00:00:00:00:00:00:02"}
13 ${node3} "node":{"type":"OF","id":"00:00:00:00:00:00:00:03"}
14 ${nodeconn1} "nodeConnector":{"type":"OF","node":{"type":"OF","id":"00:00:00:00:00:00:00:01"},"id":"1"}
15 ${nodeconn2} "nodeConnector":{"type":"OF","node":{"type":"OF","id":"00:00:00:00:00:00:00:01"},"id":"2"}
16 ${nodeconn3} "nodeConnector":{"type":"OF","node":{"type":"OF","id":"00:00:00:00:00:00:00:02"},"id":"1"}
17 ${nodeconn4} "nodeConnector":{"type":"OF","node":{"type":"OF","id":"00:00:00:00:00:00:00:02"},"id":"2"}
18 ${nodeconn5} "nodeConnector":{"type":"OF","node":{"type":"OF","id":"00:00:00:00:00:00:00:02"},"id":"3"}
19 ${nodeconn6} "nodeConnector":{"type":"OF","node":{"type":"OF","id":"00:00:00:00:00:00:00:03"},"id":"1"}
20 ${nodeconn7} "nodeConnector":{"type":"OF","node":{"type":"OF","id":"00:00:00:00:00:00:00:03"},"id":"2"}
21 ${nodeconn8} "nodeConnector":{"type":"OF","node":{"type":"OF","id":"00:00:00:00:00:00:00:03"},"id":"3"}
24 ${REST_CONTEXT} /controller/nb/v2/statistics
28 [Documentation] Show port stats and validate result
30 ${resp} Get session ${REST_CONTEXT}/${CONTAINER}/port
31 Should Contain ${resp.content} ${nodeconn1}
32 Should Contain ${resp.content} ${nodeconn2}
33 Should Contain ${resp.content} ${nodeconn3}
34 Should Contain ${resp.content} ${nodeconn4}
35 Should Contain ${resp.content} ${nodeconn5}
36 Should Contain ${resp.content} ${nodeconn6}
37 Should Contain ${resp.content} ${nodeconn7}
38 Should Contain ${resp.content} ${nodeconn8}
40 [Documentation] Show flow stats and validate result
42 ${resp} Get session ${REST_CONTEXT}/${CONTAINER}/flow
43 Should Contain ${resp.content} ${node1}
44 Should Contain ${resp.content} ${node2}
45 Should Contain ${resp.content} ${node3}
47 [Documentation] Show flow stats and validate result
49 ${resp} Get session ${REST_CONTEXT}/${CONTAINER}/table
50 Should Contain ${resp.content} ${node1}
51 Should Contain ${resp.content} ${node2}
52 Should Contain ${resp.content} ${node3}