aboutsummaryrefslogtreecommitdiffstats
path: root/tests/suites/honeycomb
diff options
context:
space:
mode:
authorselias <samelias@cisco.com>2016-06-30 16:29:25 +0200
committerMatej Klotton <mklotton@cisco.com>2016-07-11 12:33:38 +0000
commitd5e00c67d229e6f6fd9461755423cee800a1635e (patch)
treea892530d93916bc75cd5b1403958a9f5eca76cf2 /tests/suites/honeycomb
parent3bb84bee3516c1e7326becfc3c2f70bf6e3f59ce (diff)
CSIT-184: Add Honeycomb sub-interface ipv4 tests
- add tests for sub-interface ipv4 support - add keywords and methods used in tests Change-Id: I98af193a4c4f0d3822eb9637f01acead37accb8c Signed-off-by: selias <samelias@cisco.com>
Diffstat (limited to 'tests/suites/honeycomb')
-rw-r--r--tests/suites/honeycomb/060_sub_interface.robot57
-rw-r--r--tests/suites/honeycomb/resources/sub_interfaces.py10
2 files changed, 67 insertions, 0 deletions
diff --git a/tests/suites/honeycomb/060_sub_interface.robot b/tests/suites/honeycomb/060_sub_interface.robot
index 8f43a52e2e..595bbde2b7 100644
--- a/tests/suites/honeycomb/060_sub_interface.robot
+++ b/tests/suites/honeycomb/060_sub_interface.robot
@@ -329,6 +329,63 @@
| | And rewrite tag from VAT should be
| | ... | ${node} | ${sub_if_name} | ${tag_rewrite_disabled_VAT}
+| Honeycomb configures sub-interface ipv4 address
+| | [Documentation] | Check if Honeycomb can configure an ipv4 address on the\
+| | ... | sub-interface.
+| | ...
+| | Given sub-interface ipv4 address from Honeycomb should be empty
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | And sub-interface ipv4 address from VAT should be empty
+| | ... | ${node} | ${sub_if_name}
+| | When Honeycomb sets sub-interface ipv4 address
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | ... | ${ipv4['address']} | ${ipv4['prefix-length']}
+| | Then sub-interface ipv4 address from Honeycomb should be
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | ... | ${ipv4['address']} | ${ipv4['prefix-length']}
+| | And sub-interface ipv4 address from VAT should be
+| | ... | ${node} | ${sub_if_name}
+| | ... | ${ipv4['address']} | ${ipv4['prefix-length']}
+
+| Honeycomb removes sub-interface ipv4 address
+| | [Documentation] | Check if Honeycomb can remove configured ipv4 addresses\
+| | ... | from the sub-interface.
+| | ...
+| | Given sub-interface ipv4 address from Honeycomb should be
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | ... | ${ipv4['address']} | ${ipv4['prefix-length']}
+| | And sub-interface ipv4 address from VAT should be
+| | ... | ${node} | ${sub_if_name}
+| | ... | ${ipv4['address']} | ${ipv4['prefix-length']}
+| | When Honeycomb removes all sub-interface ipv4 addresses
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | Then sub-interface ipv4 address from Honeycomb should be empty
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | And sub-interface ipv4 address from VAT should be empty
+| | ... | ${node} | ${sub_if_name}
+
+| Honeycomb modifies existing sub-interface ipv4 address
+| | [Documentation] | Check if Honeycomb can modify an ipv4 address already\
+| | ... | configured on the sub-interface.
+| | [Teardown] | Honeycomb removes all sub-interface ipv4 addresses
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | Given sub-interface ipv4 address from Honeycomb should be empty
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | And sub-interface ipv4 address from VAT should be empty
+| | ... | ${node} | ${sub_if_name}
+| | When Honeycomb sets sub-interface ipv4 address
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | ... | ${ipv4['address']} | ${ipv4['prefix-length']}
+| | And Honeycomb sets sub-interface ipv4 address
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | ... | ${ipv4_2['address']} | ${ipv4_2['prefix-length']}
+| | Then sub-interface ipv4 address from Honeycomb should be
+| | ... | ${node} | ${super_if} | ${sub_if_id}
+| | ... | ${ipv4_2['address']} | ${ipv4_2['prefix-length']}
+| | And sub-interface ipv4 address from VAT should be
+| | ... | ${node} | ${sub_if_name}
+| | ... | ${ipv4_2['address']} | ${ipv4_2['prefix-length']}
+
*** Keywords ***
| Set super and sub interfaces up
| | [Documentation] | Honeycomb sets super-interface and sub-interface up, in \
diff --git a/tests/suites/honeycomb/resources/sub_interfaces.py b/tests/suites/honeycomb/resources/sub_interfaces.py
index e4acd004ac..6904b48015 100644
--- a/tests/suites/honeycomb/resources/sub_interfaces.py
+++ b/tests/suites/honeycomb/resources/sub_interfaces.py
@@ -275,3 +275,13 @@ tag_rewrite_translate_1_2_wrong = {
}
]
}
+
+# IP addresses configured on sub-interface during tests
+ipv4 = {
+ "address": "192.168.0.4",
+ "netmask": "255.255.255.0",
+ "prefix-length": 24}
+ipv4_2 = {
+ "address": "192.168.0.5",
+ "netmask": "255.255.0.0",
+ "prefix-length": 16}