diff options
author | kubi <jean.gaoliang@huawei.com> | 2015-07-28 09:17:02 +0000 |
---|---|---|
committer | kubi <jean.gaoliang@huawei.com> | 2015-07-28 09:17:02 +0000 |
commit | 120cf2893a4cc8871dc55c56ce019301f55cad3d (patch) | |
tree | 11f58385963ced6fe9f2ea0c5c315d7e1123bc03 | |
parent | ab4371757c7223d59dddc7bece1d3afa4dc3814b (diff) |
Fix a bug for algorithm of arithmetic runner.
since value will overstep the stop value under some condition
JIRA:YARDSTICK-97
Change-Id: I11656206fc9b576283d243a3be249276dba03759
Signed-off-by: kubi <jean.gaoliang@huawei.com>
-rwxr-xr-x[-rw-r--r--] | yardstick/benchmark/runners/arithmetic.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/yardstick/benchmark/runners/arithmetic.py b/yardstick/benchmark/runners/arithmetic.py index 9efafffec..f73d1cd0c 100644..100755 --- a/yardstick/benchmark/runners/arithmetic.py +++ b/yardstick/benchmark/runners/arithmetic.py @@ -48,8 +48,9 @@ def _worker_process(queue, cls, method_name, context, scenario_args): sla_action = None if "sla" in scenario_args: sla_action = scenario_args["sla"].get("action", "assert") + margin = 1 if step > 0 else -1 - for value in range(start, stop+step, step): + for value in range(start, stop+margin, step): options[arg_name] = value |