Merge "Fix up formatting on devguide"
[yardstick.git] / yardstick / benchmark / scenarios / networking / vnf_generic.py
index 4f7ef60..eb62d62 100644 (file)
@@ -23,6 +23,7 @@ import time
 import six
 import yaml
 
+from yardstick.benchmark.contexts import base as context_base
 from yardstick.benchmark.scenarios import base as scenario_base
 from yardstick.common.constants import LOG_DIR
 from yardstick.common import exceptions
@@ -36,6 +37,7 @@ from yardstick.network_services.traffic_profile import base as tprofile_base
 from yardstick.network_services.utils import get_nsb_option
 from yardstick import ssh
 
+
 traffic_profile.register_modules()
 
 
@@ -136,7 +138,7 @@ class NetworkServiceTestCase(scenario_base.Scenario):
     def _get_duration(self):
         options = self.scenario_cfg.get('options', {})
         return options.get('duration',
-                           tprofile_base.TrafficProfile.DEFAULT_DURATION)
+                           tprofile_base.TrafficProfileConfig.DEFAULT_DURATION)
 
     def _fill_traffic_profile(self):
         tprofile = self._get_traffic_profile()
@@ -448,7 +450,7 @@ class NetworkServiceTestCase(scenario_base.Scenario):
             traffic_gen.listen_traffic(self.traffic_profile)
 
         # register collector with yardstick for KPI collection.
-        self.collector = Collector(self.vnfs)
+        self.collector = Collector(self.vnfs, context_base.Context.get_physical_nodes())
         self.collector.start()
 
         # Start the actual traffic