summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorchenjiankun <chenjiankun1@huawei.com>2017-07-04 03:16:55 +0000
committerchenjiankun <chenjiankun1@huawei.com>2017-07-04 03:16:55 +0000
commit8e2da9dd467f0e0a28bb92097d80d707d579bd4f (patch)
tree9b43c9b3c86970e4b59c6b0f7f62d27c8f9b16e1
parent241b693baaec90347d08e63eb1dc167a0033ec21 (diff)
Bugfix: background scenario can't not update result
JIRA: YARDSTICK-700 In this patch: https://gerrit.opnfv.org/gerrit/#/c/35257/ In yardstick/benchmark/core/task.py We update background result only when it be stopped abnormally. We need move it out of 'if' statement. Change-Id: I25b76e160273a87da66098565a16e4a143cec11f Signed-off-by: chenjiankun <chenjiankun1@huawei.com>
-rw-r--r--yardstick/benchmark/core/task.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/yardstick/benchmark/core/task.py b/yardstick/benchmark/core/task.py
index 9c6caf03f..d1a4d7561 100644
--- a/yardstick/benchmark/core/task.py
+++ b/yardstick/benchmark/core/task.py
@@ -250,10 +250,12 @@ class Task(object): # pragma: no cover
# Nuke if it did not stop nicely
base_runner.Runner.terminate(runner)
status = runner_join(runner)
- self.outputs.update(runner.get_output())
- result.extend(runner.get_result())
else:
base_runner.Runner.release(runner)
+
+ self.outputs.update(runner.get_output())
+ result.extend(runner.get_result())
+
if status != 0:
raise RuntimeError
print("Background task ended")