Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org 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 smtp.lore.kernel.org (Postfix) with ESMTPS id E756CC0015E for ; Sun, 16 Jul 2023 00:42:03 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id A3253863EC; Sun, 16 Jul 2023 02:38:52 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="c6D6lawI"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id A3687865C0; Sun, 16 Jul 2023 02:37:53 +0200 (CEST) Received: from mail-io1-xd2f.google.com (mail-io1-xd2f.google.com [IPv6:2607:f8b0:4864:20::d2f]) (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 832EA86281 for ; Sun, 16 Jul 2023 02:37:44 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd2f.google.com with SMTP id ca18e2360f4ac-7835ffc53bfso71047439f.1 for ; Sat, 15 Jul 2023 17:37:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1689467863; x=1692059863; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=O2RgjR8W/dtzUVihTu+xeFIM3p3mpG3Vlm0dStKD9DM=; b=c6D6lawIdyY2Lgm2UGOx484V6+08AjKBYbN/yNHJFC6GEBrLDQRa1WRLvsmi019JPb S1h4FKfC11ezpBITVb1cyaG7UaqdlQDhXcG9ff/xD84qKOHAXtWT8XTPJ8q+Rp+DD20q 9VUHyAb2nlVKyErz4PjSRwtDRyhzI7XBmUG/o= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689467863; x=1692059863; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=O2RgjR8W/dtzUVihTu+xeFIM3p3mpG3Vlm0dStKD9DM=; b=NrAGTUmZRswlgJBEpMQwgN1b/GG6XTglGyUnVIriTt9po7HgQ/95kVqEYRjjKlu6CP TWoRrrkXA+k538L2YQzEokVKc6v1dlzpiNYe236JRYaEVN/gUjf1xg5JkF2fHlZsISa4 YDL5P0gbUSedAavYtiHYf88hCNiw7rFABo7sPolzAmY11lRrn8qtQ0YCLGqZrzt9zjm4 xmA5hoL6C+pQ0On2fXgpQVkXbla1vZ2coUMPb/WO9D0iAAQTApuNoNheNzuqAtn+v4YT 4ykvawkv8ycLt6SSRLaR5OBmC0DfH+DHC4sytaPogYxrirh7kM/v6W2EmK0ydfmZOX6D IrxQ== X-Gm-Message-State: ABy/qLaipRDB+HpzVDjvwGkKVLZftJP9WbIrLwpf44afWZTRKFaiFj3s I2nIDvGctAnMn4pzcAW7UhYNmAOl2wXePPZYp50= X-Google-Smtp-Source: APBJJlEAUAXbt8YwrMgpKiF/8Arc8vR+AdCj9rCNVkdslNDOi41jFI0CAG1jXr50sCLWxIDquT2OSg== X-Received: by 2002:a6b:3bcf:0:b0:785:cac9:2d49 with SMTP id i198-20020a6b3bcf000000b00785cac92d49mr4929816ioa.1.1689467863136; Sat, 15 Jul 2023 17:37:43 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id t3-20020a05663801e300b0042b52dc77e3sm3510512jaq.158.2023.07.15.17.37.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 15 Jul 2023 17:37:42 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Mike Frysinger , Simon Glass Subject: [PATCH v3 28/81] buildman: Add tests for excluding things Date: Sat, 15 Jul 2023 18:35:56 -0600 Message-ID: <20230716003718.231903-29-sjg@chromium.org> X-Mailer: git-send-email 2.41.0.455.g037347b96a-goog In-Reply-To: <20230716003718.231903-1-sjg@chromium.org> References: <20230716003718.231903-1-sjg@chromium.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 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.8 at phobos.denx.de X-Virus-Status: Clean Add some tests for the -x flag. Signed-off-by: Simon Glass --- Changes in v3: - Add new patch to test for excluding things tools/buildman/func_test.py | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/tools/buildman/func_test.py b/tools/buildman/func_test.py index 6753a4098942..e9720899e2ee 100644 --- a/tools/buildman/func_test.py +++ b/tools/buildman/func_test.py @@ -1006,3 +1006,27 @@ endif result = self._RunControl('-A', 'board0') self.assertEqual('arm-\n', stdout.getvalue()) self.assertEqual('', stderr.getvalue()) + + def test_exclude_one(self): + """Test excluding a single board from an arch""" + self._RunControl('arm', '-x', 'board1') + self.assertEqual(['board0'], + [b.target for b in self._boards.get_selected()]) + + def test_exclude_arch(self): + """Test excluding an arch""" + self._RunControl('-x', 'arm') + self.assertEqual(['board2', 'board4'], + [b.target for b in self._boards.get_selected()]) + + def test_exclude_comma(self): + """Test excluding a comma-separated list of things""" + self._RunControl('-x', 'arm,powerpc') + self.assertEqual(['board4'], + [b.target for b in self._boards.get_selected()]) + + def test_exclude_list(self): + """Test excluding a list of things""" + self._RunControl('-x', 'board2', '-x' 'board4') + self.assertEqual(['board0', 'board1'], + [b.target for b in self._boards.get_selected()]) -- 2.41.0.455.g037347b96a-goog