From 1e1138cdc36ab308568e51314d967f7d13bdacc5 Mon Sep 17 00:00:00 2001 From: "Sridhar K. N. Rao" Date: Wed, 14 Sep 2016 22:42:05 +0530 Subject: pkt_gen: Spirent Testcenter RFC 2889 Support The changes/additions, apart from spirent testcenter-specific, also includes to some files in conf (01_testcase and 03_traffic) and core (result- constants, traffic_controller and component_factory) folders. Currently, only RFC2889 Forwarding testcase is supported. Incorporated following review suggestions: 1. Log level fixes 2. Removing unused function in results_constants.py 3. Added documentation to docs/configguide/trafficgen.rst. Userguide will be updated once other RFC2889 tests are implemented. 4. string matching in component_factory. 5. Remove Trailing Whitespaces JIRA: VSPERF-286 Change-Id: I0195720ab2f8cf2c3a5aa490d66166bdca0afcb0 Signed-off-by: Sridhar K. N. Rao --- core/component_factory.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'core/component_factory.py') diff --git a/core/component_factory.py b/core/component_factory.py index 7f453bd2..ef7ba86f 100644 --- a/core/component_factory.py +++ b/core/component_factory.py @@ -16,6 +16,7 @@ """ from core.traffic_controller_rfc2544 import TrafficControllerRFC2544 +from core.traffic_controller_rfc2889 import TrafficControllerRFC2889 from core.vswitch_controller_clean import VswitchControllerClean from core.vswitch_controller_p2p import VswitchControllerP2P from core.vswitch_controller_pxp import VswitchControllerPXP @@ -47,7 +48,10 @@ def create_traffic(traffic_type, trafficgen_class): :param trafficgen_class: Reference to traffic generator class to be used. :return: A new ITrafficController """ - return TrafficControllerRFC2544(trafficgen_class) + if traffic_type.lower().startswith('rfc2889'): + return TrafficControllerRFC2889(trafficgen_class) + else: + return TrafficControllerRFC2544(trafficgen_class) def create_vswitch(deployment_scenario, vswitch_class, traffic, -- cgit 1.2.3-korg