From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-21.7 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 53345C4338F for ; Tue, 27 Jul 2021 17:01:58 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 3292760F37 for ; Tue, 27 Jul 2021 17:01:57 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 3292760F37 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 10466831C2; Tue, 27 Jul 2021 19:01:55 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 25368831D6; Tue, 27 Jul 2021 19:01:54 +0200 (CEST) Received: from mail-qt1-f181.google.com (mail-qt1-f181.google.com [209.85.160.181]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 36AC7831C2 for ; Tue, 27 Jul 2021 19:01:50 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=tom.rini@gmail.com Received: by mail-qt1-f181.google.com with SMTP id d9so9972004qty.12 for ; Tue, 27 Jul 2021 10:01:50 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=5fCBMFmcu40vOcrW0vfZlfMHqEcDNpIhv5r3+dQqFno=; b=ARcO/YdwCEGIxfJFIFddgNoCl+iIsn7yWVviN8eNPkQb71YmCNFV528W/NZrVBt83B r1vkopWAAmOU2zGnXapdDnBgMYiml1nC+JdHjlUyrgBoOyVDMIUEISqEHYzj9dhV2dTc q/IwuCJzCKrClD9Sa8rkxKfUvuNgDWPnmVENN4AGvGAYGaU2zQmKkgukBaWIIHPaq65B 7Vmioe5j5Zher+BEbmrqsGUiNUAJFe3TqqPi+meb/R4wA8wEAFiBI14JeOi+SBeitb27 6AnHejIowzggB9pP0Rj7ExjCuo2dlGXqQHKjnwWKLTUpfzb1x0dG2tYcQS6O59KAWSf6 AKqw== X-Gm-Message-State: AOAM532rRdmk0SomX2Io4+v/Hvs4ejO5Vwg7o1vSZ23UqWJVN+opQZXl b06vVZj0HnILL8kAhcnCny0PA5nZQVsa X-Google-Smtp-Source: ABdhPJy3FQjDYPRS/RlS9oPXvD5/E2zs2YjuE/cL00EzFp7vcddfXFf0c/XwparDYPEHmmzrk/ZVKQ== X-Received: by 2002:a05:622a:14d3:: with SMTP id u19mr20448388qtx.258.1627405308375; Tue, 27 Jul 2021 10:01:48 -0700 (PDT) Received: from bill-the-cat.lan (2603-6081-7b01-cbda-9c07-e31a-fc07-a573.res6.spectrum.com. [2603:6081:7b01:cbda:9c07:e31a:fc07:a573]) by smtp.gmail.com with ESMTPSA id g206sm1988708qke.13.2021.07.27.10.01.47 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 27 Jul 2021 10:01:47 -0700 (PDT) From: Tom Rini To: u-boot@lists.denx.de Subject: [PATCH] doc: Add basic information about running CI tests Date: Tue, 27 Jul 2021 13:01:44 -0400 Message-Id: <20210727170144.25563-1-trini@konsulko.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20210727170051.25396-1-trini@konsulko.com> References: <20210727170051.25396-1-trini@konsulko.com> X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean Start out by documenting general expectations on when CI is run, how anyone can run Azure pipelines, and how GitLab CI pipelines can be run. Signed-off-by: Tom Rini --- Changes in v3: - Really address all of the feedback. Changes in v2: - Address some of Akashi-san's feedback --- doc/develop/ci_testing.rst | 70 ++++++++++++++++++++++++++++++++++++++ doc/develop/index.rst | 1 + 2 files changed, 71 insertions(+) create mode 100644 doc/develop/ci_testing.rst diff --git a/doc/develop/ci_testing.rst b/doc/develop/ci_testing.rst new file mode 100644 index 000000000000..b9a9a516c1e6 --- /dev/null +++ b/doc/develop/ci_testing.rst @@ -0,0 +1,70 @@ +.. SPDX-License-Identifier: GPL-2.0+ + +Continuous Integration testing +============================== + +All changes require passing our continuous integration tests prior to being +merged in to mainline. To help facilitate merges being accepted quickly, +custodians are encouraged but not required to run a pipeline prior to sending a +pull request. Individual developers submitting significant or widespread +changes are encouraged to run a pipeline themselves prior to posting. + +In order to make this process as easy as possible, the ability to run a CI +pipeline is provided in both Azure and GitLab. Both of these pipelines perform +their Linux build jobs on the same Docker container image and to cover the same +platforms. In addition, Azure is also used to confirm that our host tools can +be built with mingw to run on Windows. + +Each of the pipelines is written in such as way as to be a "world build" style +test and as such we try and build all possible platforms. In addition, for all +platforms that support being run in QEMU we run them in QEMU and use our pytest +suite. See :doc:`py_testing` for more information about those tests. + +Azure Pipelines +--------------- + +This pipeline is defined in the top-level ``.azure-pipelines.yml`` file. +Currently there are two ways to run a Microsoft Azure Pipeline test for U-Boot. + +The first way is to create an account with Microsoft at +https://azure.microsoft.com/en-us/services/devops/ and then use the +``.azure-pipelines.yml`` file in the U-Boot repository as the pipeline +description. + +The second way is to use GitHub. This requires a GitHub account +and to fork the repository at https://github.com/u-boot/u-boot and to then +submit a pull request as this will trigger an Azure pipeline run. Clicking on +your pull request on the list at https://github.com/u-boot/u-boot/pulls and +then the "Checks" tab will show the results. + +GitLab CI Pipelines +------------------- + +This pipeline is defined in the top-level ``.gitlab-ci.yml`` file. Currently, +we support running GitLab CI pipelines only for custodians, due to the +resources the project has available. For Custodians, it is a matter of +enabling the pipeline feature in your project repository following the standard +GitLab documentation. For non-custodians, the pipeline itself is part of the +tree and should be able to be used on any GitLab instance, with whatever +runners you are able to provide. While it is intended to be able to run this +pipeline on the free public instances provided at https://gitlab.com/ a problem +with our squashfs tests currently prevents this. + +Docker container +---------------- + +As previously stated, both of the above pipelines build using the same Docker +container image. This is maintained in the U-Boot source tree at +``tools/docker/Dockerfile`` and new images are made as needed to support new +tests or features. This file needs to be updated whenever adding new external +tool requirements to tests. + +Customizing CI +-------------- + +As noted above, the CI pipelines perform a world build. While this is good for +overall project testing, it can be less useful for testing specific cases or +developing features. In that case, it can be useful as part of your own +testing cycle to edit these pipelines in separate local commits to pair them +down to just the jobs you're interested in. These changes must be removed +prior to submission. diff --git a/doc/develop/index.rst b/doc/develop/index.rst index 54e14dd77b5e..3c0f2da44318 100644 --- a/doc/develop/index.rst +++ b/doc/develop/index.rst @@ -9,6 +9,7 @@ Implementation .. toctree:: :maxdepth: 1 + ci_testing commands driver-model/index global_data -- 2.17.1