Show accessibility report from dynamically generated child pipelines in a MR
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
Proposal
In http://gitlab.com/gitlab-org/gitlab/blob/dde3a70e1d9c21f0f5698d16f3f0f239b0836a4a/app/serializers/merge_request_poll_cached_widget_entity.rb#L128-L132, we expose test reports path to the frontend using merge_request.has_accessibility_reports?, which in turn checks if the head pipeline has accessibility reports in latest_report_builds. http://gitlab.com/gitlab-org/gitlab/blob/dde3a70e1d9c21f0f5698d16f3f0f239b0836a4a/app/models/ci/pipeline.rb#L1068-L1070
This in turn is used to return the actual accessibility report in http://gitlab.com/gitlab-org/gitlab/blob/dde3a70e1d9c21f0f5698d16f3f0f239b0836a4a/app/models/ci/pipeline.rb#1102-L1106.
So to support the reports from child pipeline, we need to
- Use
Pipeline#has_reports_in_self_and_descendants?introduced in #363301 (closed) to expose the accessibilty reports path - Use
Pipeline#latest_report_builds_in_self_and_descendantsintroduced in #363301 (closed) to fetch the actual accessibility reports from the pipeline and its descendants.