Rename Honeycomb test suites 99/1799/3
authorselias <samelias@cisco.com>
Wed, 29 Jun 2016 08:38:31 +0000 (10:38 +0200)
committerMatej Klotton <mklotton@cisco.com>
Thu, 30 Jun 2016 08:35:58 +0000 (08:35 +0000)
 - update test suite numbering to be future-proof
 - reorder suite execution:
   - persistence suite should always run last
   - l2_fib suite follows after l2
   - VxLAN gpe suite follows after VxLAN
 - fix issue with interface name vs. index introduced in change #1032
 - change ${node} variable to global scope, set in _init_.robot

Change-Id: Ib4ca7265586026faab219da9923e7ca312ef2c79
Signed-off-by: selias <samelias@cisco.com>
13 files changed:
resources/libraries/robot/honeycomb/bridge_domain.robot
resources/libraries/robot/honeycomb/interfaces.robot
tests/suites/honeycomb/010_interface_management.robot [moved from tests/suites/honeycomb/1 - interface_management.robot with 98% similarity]
tests/suites/honeycomb/020_bridge_domain.robot [moved from tests/suites/honeycomb/3 - bridge_domain.robot with 98% similarity]
tests/suites/honeycomb/021_l2_fib.robot [moved from tests/suites/honeycomb/9 - l2_fib.robot with 98% similarity]
tests/suites/honeycomb/030_vxlan.robot [moved from tests/suites/honeycomb/2 - vxlan.robot with 98% similarity]
tests/suites/honeycomb/031_vxlan_gpe.robot [moved from tests/suites/honeycomb/8 - vxlan_gpe.robot with 99% similarity]
tests/suites/honeycomb/040_tap.robot [moved from tests/suites/honeycomb/4 - tap.robot with 97% similarity]
tests/suites/honeycomb/050_interface_vhost_user.robot [moved from tests/suites/honeycomb/5 - interface_vhost_user.robot with 99% similarity]
tests/suites/honeycomb/060_sub_interface.robot [moved from tests/suites/honeycomb/6 - sub_interface.robot with 99% similarity]
tests/suites/honeycomb/070_notification.robot [moved from tests/suites/honeycomb/9 - notification.robot with 97% similarity]
tests/suites/honeycomb/900_persistence.robot [moved from tests/suites/honeycomb/7 - persistence.robot with 96% similarity]
tests/suites/honeycomb/__init__.robot

index 76122fa..f8951e6 100644 (file)
 | | ... | \| GigabitEthernet0/9/0 \| ${{split_horizon_group:2, bvi:False}} \|
 | | [Arguments] | ${node} | ${index} | ${interface1} | ${interface2}
 | | ... | ${settings}
-| | ${if1_index}= | Get interface sw index | ${node} | ${interface1}
-| | ${if2_index}= | Get interface sw index | ${node} | ${interface2}
-| | ${if_indices}= | Create list | ${if1_index} | ${if2_index}
+| | ${if1_link}= | Get interface by name | ${node} | ${interface1}
+| | ${if2_link}= | Get interface by name | ${node} | ${interface2}
+| | ${if_indices}= | Create list
+| | ... | ${node['interfaces']['${if1_link}']['vpp_sw_index']}
+| | ... | ${node['interfaces']['${if2_link}']['vpp_sw_index']}
 | | ${bd_data}= | VPP get bridge domain data | ${node}
 | | ${bd_interfaces}= | Set Variable | ${bd_data[${index}]['sw_if']}
 | | @{bd_interfaces}= | Create List | ${bd_interfaces[0]} | ${bd_interfaces[1]}
index ea1d2b0..8321342 100644 (file)
@@ -33,6 +33,7 @@
 | | ... | \| up \|
 | | [Arguments] | ${node} | ${interface} | ${state}
 | | interfaceCLI.Set interface state | ${node} | ${interface} | ${state}
+| | ... | if_type=name
 
 | Honeycomb sets interface state
 | | [Documentation] | Uses Honeycomb API to change the admin state\
 | | Should be equal | ${prefix}
 | | ... | ${api_data['ietf-ip:ipv4']['address'][0]['prefix-length']}
 | | Should be equal | ${fib_address}
-| | ... | ${api_data['ietf-ip:ipv4']['neighbor'][0]['ip']
+| | ... | ${api_data['ietf-ip:ipv4']['neighbor'][0]['ip']}
 | | Should be equal | ${fib_mac}
-| | ... | ${api_data['ietf-ip:ipv4']['neighbor'][0]['link-layer-address']
+| | ... | ${api_data['ietf-ip:ipv4']['neighbor'][0]['link-layer-address']}
 | | :FOR | ${key} | IN | @{settings.keys()}
 | | | Should be equal
 | | | ... | ${settings['{key']} | ${api_data['ietf-ip:ipv4']['{$key}']}
@@ -12,8 +12,7 @@
 # limitations under the License.
 
 *** Variables ***
-# Node and interface to run tests on.
-| ${node}= | ${nodes['DUT1']}
+# Interface to run tests on.
 | ${interface}= | ${node['interfaces']['port1']['name']}
 # Configuration which will be set and verified during tests.
 | ${ipv4_address}= | 192.168.0.2
@@ -12,8 +12,7 @@
 # limitations under the License.
 
 *** Variables ***
-# Node and interfaces to run tests on.
-| ${node}= | ${nodes['DUT1']}
+# Interfaces to run tests on.
 | @{interfaces}= | ${node['interfaces']['port1']['name']}
 | ... | ${node['interfaces']['port3']['name']}
 # Configuration which will be set and verified during tests.
similarity index 98%
rename from tests/suites/honeycomb/9 - l2_fib.robot
rename to tests/suites/honeycomb/021_l2_fib.robot
index bc56f4e..c994ad3 100644 (file)
@@ -26,9 +26,8 @@
 | Force tags | honeycomb_sanity
 
 *** Variables ***
-# Node and interface used in tests.
-| ${node}= | ${nodes['DUT1']}
-| ${interface}= | GigabitEthernet0/8/0
+# Interface to run tests on.
+| ${interface}= | ${node['interfaces']['port1']['name']}
 
 *** Test Cases ***
 | Honeycomb adds L2 FIB entry (forward)
similarity index 98%
rename from tests/suites/honeycomb/2 - vxlan.robot
rename to tests/suites/honeycomb/030_vxlan.robot
index c49c14c..03a3d71 100644 (file)
@@ -12,8 +12,7 @@
 # limitations under the License.
 
 *** Variables ***
-# Node and interfaces to run tests on.
-| ${node}= | ${nodes['DUT1']}
+# Interfaces to run tests on.
 | ${interface}= | ${node['interfaces']['port1']['name']}
 | ${vx_interface}= | vx_tunnel_test
 # Configuration which will be set and verified during tests.
similarity index 99%
rename from tests/suites/honeycomb/8 - vxlan_gpe.robot
rename to tests/suites/honeycomb/031_vxlan_gpe.robot
index 0031a0a..ec2ef3a 100644 (file)
@@ -12,8 +12,7 @@
 # limitations under the License.
 
 *** Variables ***
-# Node and interfaces to run tests on.
-| ${node}= | ${nodes['DUT1']}
+# Interface to run tests on.
 | ${interface}= | ${node['interfaces']['port1']['name']}
 
 # Parameters to be set on existing interface
similarity index 97%
rename from tests/suites/honeycomb/4 - tap.robot
rename to tests/suites/honeycomb/040_tap.robot
index 4bce990..329ca8a 100644 (file)
@@ -12,8 +12,7 @@
 # limitations under the License.
 
 *** Variables ***
-# Node and interfaces to run tests on.
-| ${node}= | ${nodes['DUT1']}
+# Interfaces to run tests on.
 | ${interface}= | ${node['interfaces']['port1']['name']}
 | ${tap_interface}= | tap_test
 # Configuration which will be set and verified during tests.
@@ -12,7 +12,6 @@
 # limitations under the License.
 
 *** Variables ***
-| ${node}= | ${nodes['DUT1']}
 | ${interface}= | ${node['interfaces']['port1']['name']}
 | ${vhost_interface}= | test_vhost
 | &{vhost_user_server}= | socket=soc1 | role=server
@@ -25,8 +25,6 @@
 | ...           | delete a sub-interface.
 
 *** Variables ***
-| ${node}= | ${nodes['DUT1']}
-
 # Test interface 1 and its sub-interface parameters:
 | ${super_if}= | ${node['interfaces']['port1']['name']}
 | ${sub_if_id}= | ${sub_if_1_settings['identifier']}
@@ -36,7 +34,8 @@
 | Honycomb creates sub-interface
 | | [Documentation] | Check if Honeycomb creates a sub-interface.
 | | ...
-| | Given sub-interface configuration from Honeycomb should be empty
+| | Given interface state is | ${node} | ${super_if} | down
+| | And sub-interface configuration from Honeycomb should be empty
 | | ... | ${node} | ${super_if} | ${sub_if_id}
 | | And interface configuration from VAT should be empty
 | | ... | ${node} | ${sub_if_name}
@@ -12,8 +12,7 @@
 # limitations under the License.
 
 *** Variables ***
-# Node and interfaces to run tests on.
-| ${node}= | ${nodes['DUT1']}
+# Interfaces to run tests on.
 | ${interface}= | ${node['interfaces']['port1']['name']}
 | ${tap_interface}= | tap_test
 | &{tap_settings}= | tap-name=tap_test | mac=08:00:27:c0:5d:37
similarity index 96%
rename from tests/suites/honeycomb/7 - persistence.robot
rename to tests/suites/honeycomb/900_persistence.robot
index ad0aece..e3f68cc 100644 (file)
@@ -12,8 +12,7 @@
 # limitations under the License.
 
 *** Variables***
-# Node and interface to run tests on.
-| ${node}= | ${nodes['DUT1']}
+# Interface to run tests on.
 | ${interface}= | ${node['interfaces']['port1']['name']}
 
 *** Settings ***
index 264f604..d38852a 100644 (file)
@@ -12,6 +12,7 @@
 # limitations under the License.
 
 *** Variables***
+# Honeycomb node to run tests on.
 | ${node}= | ${nodes['DUT1']}
 
 *** Settings ***
@@ -20,5 +21,6 @@
 | Resource | resources/libraries/robot/honeycomb/honeycomb.robot
 | Suite Setup | Run keywords | Setup all DUTs before test | AND
 | ... | Clear persisted Honeycomb configuration | ${node} | AND
-| ... | Setup Honeycomb service on DUTs | ${node}
+| ... | Setup Honeycomb service on DUTs | ${node} | AND
+| ... | Set Global Variable | ${node}
 | Suite Teardown | Stop Honeycomb service on DUTs | ${node}