Skip to content

Add new ci job artifact `requirements_v2`

Felipe Cardozo requested to merge issue_329435-add_new_artifact into master

What does this MR do and why?

First part of the implementation of #329435 (comment 1178160426).

Introduces a new job artifact called requirements_v2 to reference work item of requirement type using iid, the current artifact which uses old requirement objects iids should be deprecated soon.

On a second MR we will parse work item iids and use them to switch requirement status when a CI job is triggered. There is a draft of how the full implementation should look at !104498 (closed).

How to set up and validate locally

  1. Setup a runner following these instructions. A simple one using shell can be used.
  2. Add a .gitlab-ci.yml file to a project with the following content:
requirements_confirmation:
  when: manual
  allow_failure: false
  script:
    - mkdir tmp
    - echo "{\"4\":\"failed\", \"6\":\"passed\"}" > tmp/requirements_v2.json
  artifacts:
    reports:
      requirements_v2: tmp/requirements_v2.json

  1. Trigger the job defined above in the project pipelines section

You should be able to download the file on project pipelines page using the download artifacts button.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Felipe Cardozo

Merge request reports

Loading