From 4ca16eb95c5caeec2b92334f9ef7a2d8dd234619 Mon Sep 17 00:00:00 2001 From: Pierre Equoy Date: Wed, 13 Nov 2024 15:00:20 +0100 Subject: [PATCH] Add plugin and template_id in resource and attachment results These values should be there, since all of these are jobs. --- .../plainbox/impl/providers/exporters/data/checkbox.json | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/checkbox-ng/plainbox/impl/providers/exporters/data/checkbox.json b/checkbox-ng/plainbox/impl/providers/exporters/data/checkbox.json index fca270195..53a1673e1 100644 --- a/checkbox-ng/plainbox/impl/providers/exporters/data/checkbox.json +++ b/checkbox-ng/plainbox/impl/providers/exporters/data/checkbox.json @@ -67,7 +67,7 @@ "type": "test", "project": "certification", "duration": {{ job_state.result.execution_duration if job_state.result.execution_duration else 0 }}, - "plugin": "{{ job_state.job.plugin }}", + "plugin": {{ job_state.job.plugin | jsonify | safe }}, "template_id": {{ job_state.job.template_id | jsonify | safe }} }{%- if not loop.last -%},{%- endif %} {%- endfor %} @@ -87,7 +87,9 @@ "io_log": {{ job_state.result.io_log_as_flat_text | jsonify | safe }}, "type": "test", "project": "certification", - "duration": {{ job_state.result.execution_duration if job_state.result.execution_duration else 0}} + "duration": {{ job_state.result.execution_duration if job_state.result.execution_duration else 0 }}, + "plugin": {{ job_state.job.plugin | jsonify | safe }}, + "template_id": {{ job_state.job.template_id | jsonify | safe }} }{%- if not loop.last -%},{%- endif %} {%- endfor %} ], @@ -104,7 +106,8 @@ "outcome": "{{ job_state.result.outcome }}", "comments": {{ job_state.result.comments | jsonify | safe }}, "io_log": {{ job_state.result.io_log_as_text_attachment | jsonify | safe }}, - "duration": {{ job_state.result.execution_duration if job_state.result.execution_duration else 0}}, + "duration": {{ job_state.result.execution_duration if job_state.result.execution_duration else 0 }}, + "plugin": {{ job_state.job.plugin | jsonify | safe }}, "template_id": {{ job_state.job.template_id | jsonify | safe }} }{%- if not loop.last -%},{%- endif %} {%- endfor %}