Added arm condition in install.sh to avoid installation error on ubuntu.
[yardstick.git] / yardstick / dispatcher / file.py
index 8d3c369..8acd5df 100644 (file)
@@ -29,7 +29,7 @@ class FileDispatcher(DispatchBase):
 
     __dispatcher_type__ = "File"
 
-    def __init__(self, conf):
+    def __init__(self, conf, config):
         super(FileDispatcher, self).__init__(conf)
         self.result = []
 
@@ -39,5 +39,8 @@ class FileDispatcher(DispatchBase):
     def flush_result_data(self):
         file_path = self.conf.get('file_path', consts.DEFAULT_OUTPUT_FILE)
 
-        data = {'status': 1, 'result': self.result}
+        res = utils.read_json_from_file(file_path).get('result')
+        res.extend(self.result)
+
+        data = {'status': 0, 'result': res}
         utils.write_json_to_file(file_path, data)