diff options
author | 2017-02-07 13:36:58 +0200 | |
---|---|---|
committer | 2017-02-07 13:36:58 +0200 | |
commit | d3c7c3980c60598ddd3e1da4144a6df32893f3c9 (patch) | |
tree | e3d2d807ccac04c19fccd92217252cd080526791 /scripts/automation/regression/stateless_tests | |
parent | a47b869616194551a300ff376dc2cc1f03f09d95 (diff) |
Regression: another fix for ipv6 STL test, add flag --no-dut-config to disable DUT config
Change-Id: I56c38324086cfc81d2ad0a451d528707f5357b51
Signed-off-by: Yaroslav Brustinov <ybrustin@cisco.com>
Diffstat (limited to 'scripts/automation/regression/stateless_tests')
-rw-r--r-- | scripts/automation/regression/stateless_tests/stl_general_test.py | 17 | ||||
-rwxr-xr-x | scripts/automation/regression/stateless_tests/stl_ipv6_test.py | 2 |
2 files changed, 10 insertions, 9 deletions
diff --git a/scripts/automation/regression/stateless_tests/stl_general_test.py b/scripts/automation/regression/stateless_tests/stl_general_test.py index 6470d8c2..952ed70e 100644 --- a/scripts/automation/regression/stateless_tests/stl_general_test.py +++ b/scripts/automation/regression/stateless_tests/stl_general_test.py @@ -73,14 +73,15 @@ class STLBasic_Test(CStlGeneral_Test): if not self.is_loopback: try: sys.stdout.flush() - sys.stdout.write('Configuring DUT... ') - start_time = time.time() - if CTRexScenario.router_cfg['forceCleanConfig']: - CTRexScenario.router.load_clean_config() - CTRexScenario.router.configure_basic_interfaces() - CTRexScenario.router.config_pbr(mode = "config") - CTRexScenario.router.config_ipv6_pbr(mode = "config") - sys.stdout.write('done. (%ss)\n' % int(time.time() - start_time)) + if not CTRexScenario.router_cfg['no_dut_config']: + sys.stdout.write('Configuring DUT... ') + start_time = time.time() + if CTRexScenario.router_cfg['forceCleanConfig']: + CTRexScenario.router.load_clean_config() + CTRexScenario.router.configure_basic_interfaces() + CTRexScenario.router.config_pbr(mode = "config") + CTRexScenario.router.config_ipv6_pbr(mode = "config") + sys.stdout.write('done. (%ss)\n' % int(time.time() - start_time)) except Exception as e: print('') CTRexScenario.stl_init_error = 'Could not configure device, err: %s' % e diff --git a/scripts/automation/regression/stateless_tests/stl_ipv6_test.py b/scripts/automation/regression/stateless_tests/stl_ipv6_test.py index b8173db5..1fe248a3 100755 --- a/scripts/automation/regression/stateless_tests/stl_ipv6_test.py +++ b/scripts/automation/regression/stateless_tests/stl_ipv6_test.py @@ -8,8 +8,8 @@ class STLIPv6_Test(CStlGeneral_Test): def setUp(self): CStlGeneral_Test.setUp(self) print('') - self.stl_trex.set_service_mode(ports = [0]) self.stl_trex.reset() + self.stl_trex.set_service_mode(ports = [0]) def tearDown(self): CStlGeneral_Test.tearDown(self) |