Remove testplans and suites for openstack
[integration/test.git] / tools / deployment / openstack_ha / deploy / deploy_odl_with_netvirt.robot
1 *** Settings ***
2 Documentation       Test suite to install ODL with netvirt feature and ensure of services are up.
3 ...                 To Be used with the Deployer
4
5 Library             OperatingSystem
6 Library             RequestsLibrary
7 Library             Xml
8 Resource            ../libraries/Utils.robot
9 Resource            ../libraries/OpenStackInstallUtils.robot
10 Resource            ../libraries/OpendaylightInstallUtils.robot
11 Resource            ../libraries/SystemUtils.robot
12
13 Suite Setup         OpenStackInstallUtils.Get All Ssh Connections
14 Suite Teardown      Close All Connections
15
16
17 *** Test Cases ***
18 Get ODL
19     [Documentation]    Get ODL from Nexus or Install from rpm
20     IF    '${ODL_INSTALL_MODE}' == 'RPM'
21         Install ODL From RPM In All ODL Nodes    ${ODL_RPM}
22     END
23     IF    '${ODL_INSTALL_MODE}' == 'ZIP'
24         Install ODL From ZIP In All ODL Nodes    ${ACTUAL_BUNDLE_URL}    ${BUNDLEFOLDER}
25     END
26
27 Configure Netvirt Feature as Boot
28     [Documentation]    Install Netvirt feature
29     Install ODL Feature In All ODL Nodes    odl-netvirt-openstack
30
31 Configure Clustering
32     IF    2 < ${NUM_ODL_NODES}    Configure ODL Clustering
33
34 Configure SNAT Mode
35     [Documentation]    Configure SNAT Mode as Required
36     Configure SNAT Mode In All ODL Nodes    ${ODL_NAME_MODE}
37
38 Start ODL In All Nodes
39     [Documentation]    Start ODL Service
40     Start ODL In All ODL Nodes
41
42 Check If Netvirt Is Up And Running
43     [Documentation]    Check If ODL Is Running and Active
44     Check If ODL Is Running In All Nodes    operational/network-topology:network-topology/topology/netvirt:1
45     Print All Active Ports
46
47
48 *** Keywords ***
49 Set SNAT Mode
50     [Documentation]    Configure SNAT Mode for Netvirt
51     [Arguments]    ${os_node_cxn}
52     Add Element    ${XML}    <natservice-config></natservice-config>
53     Set Element Attribute    ${XML}    xmlns    urn:opendaylight:netvirt:natservice:config    xpath=natservice-config
54     Add Element    ${XML}    <nat-mode></nat-mode>    xpath=natservice-config
55     Set Element Text    ${XML}    ${ODL_SNAT_MODE}    xpath=nat-mode
56     Save Xml    ${XML}    /tmp/netvirt-natservice-config.xml
57
58 Configure SNAT Mode In All ODL Nodes
59     [Documentation]    Configure SNAT Mode for Netvirt In All ODL Nodes
60     Set SNAT Mode    ${ODL_1_IP}
61     IF    1 < ${NUM_ODL_NODES}    Set SNAT Mode    ${ODL_2_IP}
62     IF    2 < ${NUM_ODL_NODES}    Set SNAT Mode    ${ODL_3_IP}
63     IF    3 < ${NUM_ODL_NODES}    Set SNAT Mode    ${ODL_4_IP}
64     IF    4 < ${NUM_ODL_NODES}    Set SNAT Mode    ${ODL_5_IP}