77c6930351285fb9954a6ef7ffa188def9b9da4b
[integration/test.git] / test / tools / Robot_Tool / suites / base / switch_manager.txt
1 *** Settings ***
2 Documentation     Test suite for the switch manager bundle.
3 Suite Setup       Create Session    ${ODL_CONTROLLER_SESSION}    ${PREFIX}    auth=${AUTH}
4 Suite Teardown    Delete All Sessions
5 Library           Collections
6 Library           RequestsLibrary
7 Library           ../../libraries/Common.py
8 Library           ../../libraries/SwitchManager.py
9 Variables         ../../variables/Variables.py
10 Library           ../../libraries/Topology.py
11
12 *** Variables ***
13 ${REST_CONTEXT}    /controller/nb/v2/switchmanager
14
15 *** Test Cases ***
16 List all nodes
17     [Documentation]    List all nodes and their properties in the network.
18     [Tags]    list_info
19     ${URL}    Combine Strings    ${REST_CONTEXT}    /    ${CONTAINER}    /nodes
20     Log    ${topo_tree_level}
21     ${topo_nodes}    Get Nodes From Topology    ${TOPO_TREE_LEVEL}
22     ${resp}    Get    ${ODL_CONTROLLER_SESSION}    ${URL}
23     Should Be Equal As Strings    ${resp.status_code}    200    Response status code error
24     ${jsondata}=    To JSON    ${resp.content}
25     ${nodes}    Extract All Nodes    ${jsondata}
26     Collection Should Contain    ${nodes}    ${topo_nodes}