From 8e230286998bfa7a1dfcefe2493d5bee66d2746a Mon Sep 17 00:00:00 2001 From: Yaroslav Brustinov Date: Sun, 22 May 2016 17:06:25 +0300 Subject: regression: add disconnects + delay before running examples + at end of regression revert profile udp_1ptk_simple.py and add new upd_for_benchmarks.py --- scripts/automation/regression/trex_unit_test.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'scripts/automation/regression/trex_unit_test.py') diff --git a/scripts/automation/regression/trex_unit_test.py b/scripts/automation/regression/trex_unit_test.py index aaf98708..a272fe7b 100755 --- a/scripts/automation/regression/trex_unit_test.py +++ b/scripts/automation/regression/trex_unit_test.py @@ -168,13 +168,12 @@ class CTRexTestConfiguringPlugin(Plugin): CTRexScenario.benchmark = self.benchmark CTRexScenario.modes = set(self.modes) CTRexScenario.server_logs = self.server_logs - CTRexScenario.trex = CTRexClient(trex_host = self.configuration.trex['trex_name'], - verbose = self.json_verbose) - if not self.no_daemon and not CTRexScenario.trex.check_master_connectivity(): - print('Could not connect to master daemon') - sys.exit(-1) if not self.no_daemon: - CTRexScenario.scripts_path = CTRexScenario.trex.get_trex_path() + CTRexScenario.trex = CTRexClient(trex_host = self.configuration.trex['trex_name'], + verbose = self.json_verbose) + if not CTRexScenario.trex.check_master_connectivity(): + print('Could not connect to master daemon') + sys.exit(-1) if options.ga and CTRexScenario.setup_name: CTRexScenario.GAManager = GAmanager(GoogleID = 'UA-75220362-4', UserID = CTRexScenario.setup_name, @@ -241,6 +240,9 @@ class CTRexTestConfiguringPlugin(Plugin): if self.stateless: if not self.no_daemon: CTRexScenario.trex.force_kill(False) + if CTRexScenario.stl_trex and CTRexScenario.stl_trex.is_connected(): + CTRexScenario.stl_trex.disconnect() + time.sleep(3) CTRexScenario.stl_trex = None -- cgit 1.2.3-korg