summaryrefslogtreecommitdiffstats
path: root/tools/pkt_gen/testcenter/testcenter.py
AgeCommit message (Collapse)AuthorFilesLines
2017-02-22pkt_gen: STC parameter reordering bug.Sridhar K. N. Rao1-3/+3
This patch fixes a bug caused due to wrong parameter ordering. stc_common_settings should come after rfc2544_common_settings. It also gets rid of 'Import' error for module 'conf' JIRA: VSPERF-491 Change-Id: I356294b4efdf9ebd0cea4492d3ed1cb8e04ec9b1 Signed-off-by: Sridhar K. N. Rao <sridhar.rao@spirent.com>
2017-02-13pylint: Fixing pylint errors and warningsgoldammx1-0/+21
All python files must reach pylint score 10/10. This will be regularly verified by Jenkins jobs to keep constant code quality. VSPERF specific pylintrc file was updated according to the vsperf coding standards. Distro version included in reports will be slightly different, due to migration to new python package distro. Previously used platform.distro() will be deprecated since python 3.7. JIRA: VSPERF-487 Change-Id: I934120208b9624787a3567ccaa49e14d77d7a5bf Signed-off-by: Martin Goldammer <martinx.goldammer@intel.com> Reviewed-by: Martin Klozik <martinx.klozik@intel.com> Reviewed-by: Al Morton <acmorton@att.com> Reviewed-by: Christian Trautman <ctrautma@redhat.com> Reviewed-by: Bill Michalowski <bmichalo@redhat.com> Reviewed-by: Antonio Fischetti <antonio.fischetti@intel.com> Reviewed-by: Sridhar Rao <sridhar.rao@spirent.com>
2017-01-27pkt_gen: STC - RFC 2889 Address Learning and Caching SupportSridhar K. N. Rao1-43/+148
This patch adds RFC-2889 address-learning-rate test and address-caching-capacity tests. The patch includes following changes 1. 01_testcases.conf: testcase definitions are added for new tests 2. results_constants.py: 3 new results constants are added, removed unsupported constants 3. testcenter-rfc2889-rest.py: Added support to these two new tests. Removed un-necessary synchronization of db-file. 5 new configuration parameters are added - which are explained in (4). 4. trafficgen.rst: Configuration description for rfc2889 tests are added. Stale information is removed. 5. testcenter.py: Support for two new tests are added. Separate functions for results analysis and parameter settings are added. 6. traffic_controller_rfc2889.py: Calls to functions in testcenter.py, based on the traffic_type, are added. Removed trailing whitespaces from trafficgen.rst JIRA: VSPERF-395 Change-Id: Ie6ca87519b7736e7410d7f0e60904579934af24a Signed-off-by: Sridhar K. N. Rao <sridhar.rao@spirent.com>
2016-09-21pkt_gen: Spirent Testcenter RFC 2889 SupportSridhar K. N. Rao1-0/+86
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 <sridhar.rao@spirent.com>
2016-08-12pkt_gen: Spirent changes to Harmonize test/trial terminologysridharkn1-7/+9
Added changes to make use of the tests parameter. The change is minor. Prior to this the value was taken from configuration file. With this change, the tests value is used as passed. JIRA: VSPERF-367 Change-Id: I9d1553d3b53dd19a79428ddaaacadb55fc27324f Signed-off-by: Sridhar Rao <sridhar.rao@spirent.com>
2016-08-04bugfix: Harmonize test/trial RFC2544 terminologyMartin Klozik1-2/+2
VSPERF framework was updated to follow RFC2544 definition of 'test' and 'trial' terms. Test parameter 'rfc2544_trials' was replaced by new parameter 'rfc2544_tests'. Both code and documentation were updated to reflect these changes. JIRA: VSPERF-300 Change-Id: I144a28359fd06394f1f87ef324458bafd5aad45f Signed-off-by: Martin Klozik <martinx.klozik@intel.com> Reviewed-by: Maryam Tahhan <maryam.tahhan@intel.com> Reviewed-by: Al Morton <acmorton@att.com> Reviewed-by: Christian Trautman <ctrautma@redhat.com> Reviewed-by: <bmichalo@redhat.com>
2016-07-05Spirent-TestCenter: Code Cleanup.sridharkn1-276/+136
Removal of redunant code in testcenter.py. No logic Changes. Cosmetic changes - removing redundant code of 150+ lines. JIRA: VSPERF-308 Change-Id: I4766890cdc9f3d23103b2d2090285361ac4a5197 Signed-off-by: Sridhar K. N. Rao <sridhar.rao@spirent.com>
2016-06-08Spirent Support for Continuous TrafficSridhar Rao1-2/+118
Adding changes for supporting continuous traffic for Spirent Testcenter The changes are as follows: 1. From send_cont_traffic invoke function in testcenter-rfc2544-rest.py 2. In testcenter-rfc2544-rest.py check for the traffic_custom 3. If the traffic_custom is 'cont' do additional configuration on traffic. JIRA: VSPERF-146 Change-Id: Ic963f9f0c2bd013f6e676c9d18b151ae67ff77af Signed-off-by: Sridhar Rao <sridhar.rao@spirent.com>
2016-05-04pkt_gen: Reporting FPS and MBPS from Spirent Testcentersridharkn1-8/+28
Support for reporting FPS and MBPS (TX and RX) is added. JIRA: VSPERF-285 Change-Id: Ic4b6ca02368b1808f0f985e90099cdb0b41c2afa Signed-off-by: sridharkn <sridhar.rao@spirent.com>
2016-04-07pkt_gen: Adding Support of testcenter traffic generation using STC REST API.sridharkn1-28/+155
Stcrestclient package based script is added. Support for RFC22544 backtoback, latency, frameloss are also added, along with the throughput. Comments Addressed: 1. Parameter name consistency. Ex: use duration (refer dummy.py). 2. Moved 'only the necessary contents of README to configguide/trafficgen.rst. 3. Removed README file 4. Commit message format (pkt_gen: and linewrap) 5. Merged 4 scripts (throughput/backtoback/latency/frameloss) that were rest-based into one single script. Name: testcenter-rfc2544-test.py 6. Changed year to 2016 7. Moved imports to the top (testcenter-rfc2544-rest.py) 8. Changed prints to Log (testcenter-rfc2544-rest.py) 9. Reporting the frame loss percentage. 10. Calls to frameloss and latency are not added as the 'caller' class TrafficControllerRFC2544 is only calling backtoback and throughput. 11. Changed Exception, e to Exception as e for python 3 compatibility 12. Remaining prints to debug and logger.error for errors. 13. Moved Session creation under try block. 14. Removed deadcode 15. Fixed missing docstring 16. Generic to specific Exception. 17. if-if to if-elif 18. Debug level logging only under verbose flag. 19. Fixed Arguments mismatch. 20. Ordering of the imports Note: The testcenter-rfc2544-rest.py is spawned as a separate process, and need not be wrapped in a class. JIRA: VSPERF-237 Change-Id: I05d2b24fca1da4ba67bc4d79206c5d755ebf8f20 Signed-off-by: sridharkn <sridhar.rao@spirent.com>
2015-12-14bugfix: Support paths with user's home shortcutMartin Klozik1-1/+1
VSPERF will explicitly expand any '~' to the absolute path to the user's home directory before call of subsystem.Popen method. Only calls, which process configuration values are modified. Change-Id: Ibd9399ae84bf4698c86bf8eff97ca6ce785fb3fb JIRA: VSPERF-45 Signed-off-by: Martin Klozik <martinx.klozik@intel.com> Reviewed-by: Maryam Tahhan <maryam.tahhan@intel.com> Reviewed-by: Brian Castelli <brian.castelli@spirent.com> Reviewed-by: Al Morton <acmorton@att.com>
2015-12-08pkt_gen: rename throughput_tx_* to tx_rate_*Maryam Tahhan1-3/+3
Change throughput_tx_* references to tx_rate_* so the results won't be confusing as part of the opnfv test dashboard when they become publicly available. Change-Id: Ie8cfae99a75497f15eb09d097c72c8a35df3b5f9 JIRA: VSPERF-135 Signed-off-by: Maryam Tahhan <maryam.tahhan@intel.com> Reviewed-by: Martin Klozik <martinx.klozik@intel.com> Reviewed-by: Ian Stokes <ian.stokes@intel.com> Reviewed-by: Al Morton <acmorton@att.com>
2015-12-02pkt_gen: add duration to all send functionsMaryam Tahhan1-2/+2
Allow a configurable duration for all send functions. JIRA: VSPERF-125 Change-Id: I7c6f5d136a7d7100e3990f7fdc00121b07081a80 Signed-off-by: Maryam Tahhan <maryam.tahhan@intel.com> Reviewed-by: Martin Klozik <martinx.klozik@intel.com> Reviewed-by: Billy O Mahony <billy.o.mahony@intel.com> Reviewed-by: Dino Simeon Madarang <dino.simeonx.madarang@intel.com> Reviewed-by: Radek Zetik <radekx.zetik@intel.com>
2015-10-29First phase of Spirent Traffic Gen integrationspirentbrian1-0/+164
Change-Id: Ib852c81fc8e09593411984bfb6f9bc5d5629f0c4