[Scenario][Reports] Improve scenario output format

Updates:
 * make charts.Chart plugin based, so all output related charts
   are used as plugins
 * Unify output format schema for additive and complete data,
   this includes renaming keys:
    - chart -> chart_plugin
    - widget -> chart_plugin
    - items -> data

Change-Id: Ic2a7c9308e50d8c28b7811d61a268af9bb89ce5f
This commit is contained in:
Alexander Maretskiy 2016-01-11 12:43:16 +02:00
parent e9d8c07e18
commit 59272c3f19

View File

@ -1599,12 +1599,14 @@ class FakeScenario(scenario.Scenario):
return {"data": {"a": 1}, "error": None}
def with_add_output(self):
self.add_output(additive={"title": "Additive", "chart": "Chart",
self.add_output(additive={"title": "Additive",
"description": "Additive description",
"items": [["a", 1]]},
complete={"title": "Complete", "widget": "Widget",
"data": [["a", 1]],
"chart_plugin": "FooPlugin"},
complete={"title": "Complete",
"description": "Complete description",
"data": [["a", [[1, 2], [2, 3]]]]})
"data": [["a", [[1, 2], [2, 3]]]],
"chart_plugin": "BarPlugin"})
def too_long(self, **kwargs):
pass