aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDanielMartinBuckley <daniel.m.buckley@intel.com>2018-02-28 11:55:44 +0000
committerDanielMartinBuckley <daniel.m.buckley@intel.com>2018-03-07 15:19:54 +0000
commit1b76131a65f32ebcfc83fa9b4b53d681e6ab25e1 (patch)
treeaa2ad371f56abdc1d73e9cf87c3f94512e1258c0
parent9d6339d4e00b8aa3477938347c1afe693820eb25 (diff)
NFVi Test stops after one hour even if configured context duration is longer
JIRA: YARDSTICK-1021 If the Test is to take longer than the Default Duration timer use defined test time. If not use Default Duration time Change-Id: Idacc188e199ff031310b9826238b63ed3f2ea409 Signed-off-by: Daniel Martin Buckley <daniel.m.buckley@intel.com>
-rw-r--r--yardstick/network_services/vnf_generic/vnf/sample_vnf.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/yardstick/network_services/vnf_generic/vnf/sample_vnf.py b/yardstick/network_services/vnf_generic/vnf/sample_vnf.py
index d57d7e601..8d02446c2 100644
--- a/yardstick/network_services/vnf_generic/vnf/sample_vnf.py
+++ b/yardstick/network_services/vnf_generic/vnf/sample_vnf.py
@@ -626,8 +626,10 @@ class ScenarioHelper(object):
@property
def timeout(self):
- return self.options.get('timeout', DEFAULT_VNF_TIMEOUT)
-
+ test_duration = self.scenario_cfg.get('runner', {}).get('duration',
+ self.options.get('timeout', DEFAULT_VNF_TIMEOUT))
+ test_timeout = self.options.get('timeout', DEFAULT_VNF_TIMEOUT)
+ return test_duration if test_duration > test_timeout else test_timeout
class SampleVNF(GenericVNF):
""" Class providing file-like API for generic VNF implementation """