Add support for Python 3
[yardstick.git] / yardstick / benchmark / scenarios / networking / vtc_instantiation_validation_noisy.py
index 4834a5f..fb6e762 100644 (file)
@@ -7,6 +7,7 @@
 # http://www.apache.org/licenses/LICENSE-2.0
 ##############################################################################
 
+from __future__ import absolute_import
 import logging
 import os
 
@@ -78,15 +79,21 @@ class VtcInstantiationValidationNoisy(base.Scenario):
             str(self.options['amount_of_ram'])
         test_case['params']['number_of_cores'] = \
             str(self.options['number_of_cores'])
+        test_case['params']['network'] = \
+            str(self.options['default_net_name'])
+        test_case['params']['subnet'] = \
+            str(self.options['default_subnet_name'])
 
+        res = dict()
         try:
-            result = api.FrameworkApi.execute_framework(
+            res = api.FrameworkApi.execute_framework(
                 [test_case],
                 iterations,
                 heat_template,
                 heat_template_parameters,
                 deployment_configuration,
                 openstack_credentials)
-        except Exception as e:
-            LOG.info('Exception: {}'.format(e.message))
-        LOG.info('Got output: {}'.format(result))
+        except Exception:
+            LOG.exception('Exception')
+        LOG.info('Got output: %s', res)
+        result.update(res)