Testing/CI/Integrated

From QEMU
Revision as of 15:49, 6 October 2020 by DanielBerrange (talk | contribs) (Created page with "QEMU supports a number of different public CI systems to maximise testing coverage of code submitted to QEMU. By testing code via these CI systems prior to s...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

QEMU supports a number of different public CI systems to maximise testing coverage of code submitted to QEMU.

By testing code via these CI systems prior to submission, contributors can reduce the burden on QEMU maintainers and eliminate delays in getting work accepted for merge.

Use of the CI systems prior to submission is NOT mandatory, but is encouraged especially for large / complex changes which have higher risk of causing build failures.

This document describes a way to setup personal accounts on public CI systems to facilitate pre-submission testing.

GitLab CI setup

QEMU considers GitLab to be the primary CI system, and as such new CI jobs will be placed on GitLab whenever technically possible. Thus creating an account on GitLab is the recommended first step.

Start off by creating a fork of the primary QEMU repository. This will give you a public repo which you should add as a remote in your local clone

 $ git remote add gitlab https://gitlab.com/YOUR-USER-NAME/qemu

Whenever a branch containing work needs testing it can be pushed to this remote

 $ git push gitlab +branch-name

Use of the "+" in front of the branch name forces it to replace the previously pushed branch contents, which is what will typically be required if your local branch is being rebased frequently.

Immediately after the branch has been pushed, a CI pipeline for this branch will be scheduled. If it fails GitLab will send an email notification with the details. Its progress can be monitored at the URL https://gitlab.com/YOUR-USER-NAME/qemu/-/pipelines