write line separator to output properly formatted jsonlines

This commit is contained in:
Krisztián Szűcs committed 2019-05-16 08:58:42 +02:00
1 parent 8b152b4e62
commit de8389d1e9
1 file changed
+3
+3
View File
@@ -352,9 +352,12 @@ def benchmark_diff(ctx, src, preserve, suite_filter, benchmark_filter,
regressions = 0
runner_comp = RunnerComparator(runner_cont, runner_base, threshold)
# TODO(kszucs): test that the output is properly formatted jsonlines
for comparator in runner_comp.comparisons:
regressions += comparator.regression
json.dump(comparator, output, cls=JsonEncoder)
output.write('\n')
sys.exit(regressions)