Received: by 2002:ac8:3b51:0:b0:3f3:9eb6:4eb6 with SMTP id r17csp1426029qtf; Fri, 16 Jun 2023 08:19:27 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6BO2rBTf2ajKCG/pAUvCoTafq5KUxF4xgekTpkzjdk0f/NE30k9teVUDdIpR/AHExqNK/5 X-Received: by 2002:a92:d0cf:0:b0:331:7c4f:54ec with SMTP id y15-20020a92d0cf000000b003317c4f54ecmr2430367ila.30.1686928767106; Fri, 16 Jun 2023 08:19:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686928767; cv=none; d=google.com; s=arc-20160816; b=tjL10wErQP9TX4mssSr2zPC/xVQQQi9P6hLYcnN5rLdgpO+k6mTih3flo4KluCJAdX MMqDk7sj7hBIvxsBcs5k933QURNqn0cK2tqnH8OSwzVq8ohIkpg/q+H3v38A5MQu4i+o 0zLV9dqIEmlNoTeuU5aFAhEm7Wb2Sh5Dg1hsHcuKgm6EDnPKtyAymRxb+sWtir1e2rVX DuWGp0iDLc3W4Zby9brN1MJ8mhpmqkTFPCGvx++0goANCrNHT0IueQyya+R3I+PR9aiH E9CNLDnbmvZb6QlgYS46oEt8B6jLjrBR/5VdFxG+qdEkD/j58omEIzE3mj7MJcfA6Y8Q Z/qw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=/TQ/NBF9u3IBn3xcHORueLNPUOIL2wwIG5fESfTCbFI=; b=H7rLVmYLAqQzXwP85cJlg2RDfbKeU6wc8twYWYw4l28J8HcdYNrFD+IB/7KVG6MPVe oaWnZTjSiH22JHNJ1BU2re7+ck5urHYp1MKz1zVSOjNiKv/kDQFz/qU3l2FpkT+rrgMq RuoqZc06aOQ8hTr91jVaN1Cxa4Pg33SjwT0uueeOlR1/IwjsgZIg2bnqVRrOsqCtMdEZ qPFo9SXJGeCZ1kSSMt4UbWtsymZaeJPo/uDqnH7aJSZlCrDyPHWyc/N67D5763vt+n4R uSxdXBHeqsbgvR2riM4hGO0zv5hbrvh9wgnwp2ulzpt0GJHpXrVlU/8+f2pEPplRrsYK cOJw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=W5bZQhbv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id p13-20020a63950d000000b0054fd35b2dbcsi5608520pgd.350.2023.06.16.08.18.28; Fri, 16 Jun 2023 08:19:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=W5bZQhbv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345814AbjFPPCs (ORCPT + 99 others); Fri, 16 Jun 2023 11:02:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58084 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1344623AbjFPPC0 (ORCPT ); Fri, 16 Jun 2023 11:02:26 -0400 Received: from mail-oa1-x2f.google.com (mail-oa1-x2f.google.com [IPv6:2001:4860:4864:20::2f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 51EA73A86; Fri, 16 Jun 2023 08:02:06 -0700 (PDT) Received: by mail-oa1-x2f.google.com with SMTP id 586e51a60fabf-1a83bfe7ca0so766324fac.0; Fri, 16 Jun 2023 08:02:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1686927725; x=1689519725; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=/TQ/NBF9u3IBn3xcHORueLNPUOIL2wwIG5fESfTCbFI=; b=W5bZQhbvvf1ysouwrUosFRxybLDJEya2JAdz3G5mSSV8K/TGKTVSoWQzteqrGAuvck sh8bAqtvFmu3uhOGCHY6V3wueOudvp1aQ9/XK/SlHyrYB7D086K7b+83VJlQG8bStXxC ekf3U4rWSQPW8tFhKlno1I3zugyW9jAVCa2Gye+GinkIJIk9FLnPxKyrdRY4KdYGUbhE V3jvTVfaTejNfc9Qs7OzjOdhw3rmTjSJz1glTZw+Jo2Ie8SsoNdTtUahLx7IdYXwPqXI QgOZnjuyRL2+au0HdgzuXlAhgLwPGqZthrb/e+0VvHqSTH5KigwBe65//t5C32NvPIIk rMOg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686927725; x=1689519725; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=/TQ/NBF9u3IBn3xcHORueLNPUOIL2wwIG5fESfTCbFI=; b=AqSOWQBYdoQxeNWMcM0zgmsc2XcaD8vSBAoo4yqi31WML7TV5IeVgWIItJjrKLnJZv t+LPhccuGECVcCO4NaMd8apiDd84N0t8uCE4FxcBleycRdiwDJWLy97I4Gl5jo/la1xO FMjAXR4YdeizPb2HTqFBiU7fXW32SBGO/YZT6qb5ZPNuAqbdSOt9y8Pwssrb5tt1Rg/d jsF1iSXCRl71ogjRh5B5VFYWJZFISFWQCM1Nlmc4KNSSD8jbf9fYxCX5fgnpjzQkWHZz eIJDiE7Y8uB3p3jObGdVInkAmk+3mlrE0UYuvXXousX4DKGqBiO3jugR/rCByxbNNnMn W6DA== X-Gm-Message-State: AC+VfDzE2Y4fUqD4ayguAu1LjSzbp4hs0xUHwaW95cHB7bkU0f3xIsev hAhQjwtqom2Q9Cy06+Mq1xaVo0XbfF0= X-Received: by 2002:a05:6870:1a85:b0:1a3:100f:bf41 with SMTP id ef5-20020a0568701a8500b001a3100fbf41mr2136892oab.23.1686927725364; Fri, 16 Jun 2023 08:02:05 -0700 (PDT) Received: from [192.168.54.90] (static.220.238.itcsa.net. [190.15.220.238]) by smtp.gmail.com with ESMTPSA id le13-20020a0568700c0d00b001a8f6be7debsm3411187oab.28.2023.06.16.08.02.00 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 16 Jun 2023 08:02:04 -0700 (PDT) Message-ID: <22d8e3b2-4759-2b82-cdd3-aca9bf9afd74@gmail.com> Date: Fri, 16 Jun 2023 12:00:15 -0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 Subject: Re: [PATCH v2 11/11] kbuild: rust_is_available: add test suite Content-Language: en-US To: Miguel Ojeda , Masahiro Yamada , Wedson Almeida Filho , Alex Gaynor Cc: Nathan Chancellor , Nick Desaulniers , Nicolas Schier , Boqun Feng , Gary Guo , =?UTF-8?Q?Bj=c3=b6rn_Roy_Baron?= , Benno Lossin , Alice Ryhl , Andreas Hindborg , linux-kbuild@vger.kernel.org, rust-for-linux@vger.kernel.org, linux-kernel@vger.kernel.org, patches@lists.linux.dev References: <20230616001631.463536-1-ojeda@kernel.org> <20230616001631.463536-12-ojeda@kernel.org> From: Martin Rodriguez Reboredo In-Reply-To: <20230616001631.463536-12-ojeda@kernel.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.2 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,NICE_REPLY_A, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/15/23 21:16, Miguel Ojeda wrote: > The `rust_is_available.sh` script runs for everybody compiling the > kernel, even if not using Rust. Therefore, it is important to ensure > that the script is correct to avoid breaking people's compilation. > > In addition, the script needs to be able to handle a set of subtle > cases, including parsing version strings of different tools. > > Therefore, maintenance of this script can be greatly eased with > a set of tests. > > Thus add a test suite to cover hopefully most of the setups that > the script may encounter in the wild. Extra setups can be easily > added later on if missing. > > The script currently covers all the branches of the shell script, > including several ways in which they may be entered. > > Python is used for this script, since the script under test > does not depend on Rust, thus hopefully making it easier for others > to use if the need arises. > > Signed-off-by: Miguel Ojeda > --- > [...] Reviewed-by: Martin Rodriguez Reboredo