aboutsummaryrefslogtreecommitdiffstats
path: root/yardstick/benchmark
diff options
context:
space:
mode:
authorRodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>2018-08-23 16:13:48 +0000
committerGerrit Code Review <gerrit@opnfv.org>2018-08-23 16:13:48 +0000
commit5b23c7f12857ea6d47f184046010b467949303e6 (patch)
tree7d17d3b5720fa07e136fbc4ed6f578bbf212b02f /yardstick/benchmark
parent70fa1fcf237ad41d868d8501c5a49d3331ef6adf (diff)
parenteed1b9cca960e7c7a3980d0a94b3589cf6b81eab (diff)
Merge "Fix setting `flow` configuration in TC yaml"
Diffstat (limited to 'yardstick/benchmark')
-rw-r--r--yardstick/benchmark/scenarios/networking/vnf_generic.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/yardstick/benchmark/scenarios/networking/vnf_generic.py b/yardstick/benchmark/scenarios/networking/vnf_generic.py
index 10f10d4e6..4884e57a8 100644
--- a/yardstick/benchmark/scenarios/networking/vnf_generic.py
+++ b/yardstick/benchmark/scenarios/networking/vnf_generic.py
@@ -117,8 +117,12 @@ class NetworkServiceTestCase(scenario_base.Scenario):
for index, dst_port in enumerate(fflow.get("dst_port", [])):
flow["dst_port_{}".format(index)] = dst_port
- flow["count"] = fflow["count"]
- flow["seed"] = fflow["seed"]
+ if "count" in fflow:
+ flow["count"] = fflow["count"]
+
+ if "seed" in fflow:
+ flow["seed"] = fflow["seed"]
+
except KeyError:
flow = {}
return {"flow": flow}