diff options
Diffstat (limited to 'conf/integration/01_testcases.conf')
-rw-r--r-- | conf/integration/01_testcases.conf | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/conf/integration/01_testcases.conf b/conf/integration/01_testcases.conf index 692f1561..bb2809b8 100644 --- a/conf/integration/01_testcases.conf +++ b/conf/integration/01_testcases.conf @@ -1118,6 +1118,44 @@ INTEGRATION_TESTS += [ ['tools', 'assert', '#STEP[-1][0] == 0'], ], }, + # Capture Example 3 - Traffic capture by traffic generator. + # This TestCase uses OVS flow to add VLAN tag with given ID into every + # frame send by traffic generator. Correct frame modificaiton is verified by + # inspection of packet capture received by T-Rex. + { + "Name": "capture_p2p_add_vlan_ovs_trex", + "Deployment": "clean", + "Description": "OVS: Test VLAN tag modification and verify it by traffic capture", + "vSwitch" : "OvsDpdkVhost", # works also for Vanilla OVS + "Parameters" : { + "TRAFFICGEN" : "Trex", + "TRAFFICGEN_DURATION" : 5, + "TRAFFIC" : { + "traffic_type" : "rfc2544_continuous", + "frame_rate" : 100, + # enable capture of five RX frames + 'capture': { + 'enabled': True, + 'tx_ports' : [], + 'rx_ports' : [1], + 'count' : 5, + }, + }, + }, + "TestSteps" : STEP_VSWITCH_P2P_INIT + [ + # replace standard L2 flows by flows, which will add VLAN tag with ID 3 + ['!vswitch', 'add_flow', 'int_br0', {'in_port': '1', 'actions': ['mod_vlan_vid:3','output:2']}], + ['!vswitch', 'add_flow', 'int_br0', {'in_port': '2', 'actions': ['mod_vlan_vid:3','output:1']}], + ['vswitch', 'dump_flows', 'int_br0'], + ['trafficgen', 'send_traffic', {}], + ['trafficgen', 'get_results'], + # verify that captured frames have vlan tag with ID 3 + ['tools', 'exec_shell', 'tcpdump -qer $RESULTS_PATH/#STEP[-1][0]["capture_rx"] vlan 3 ' + '2>/dev/null | wc -l', '|^(\d+)$'], + # number of received frames with expected VLAN id must match the number of captured frames + ['tools', 'assert', '#STEP[-1][0] == 5'], + ] + STEP_VSWITCH_P2P_FINIT, + }, # # End of examples of functional testcases with traffic capture validation # |