From patchwork Thu Dec 9 08:52:41 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabian Stelzer X-Patchwork-Id: 12666069 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 65EAFC433F5 for ; Thu, 9 Dec 2021 08:52:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235298AbhLII4a (ORCPT ); Thu, 9 Dec 2021 03:56:30 -0500 Received: from mail-am6eur05on2067.outbound.protection.outlook.com ([40.107.22.67]:2017 "EHLO EUR05-AM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S235264AbhLII42 (ORCPT ); Thu, 9 Dec 2021 03:56:28 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=MSe9ElfdUMVT+DXUHf9Q5F7JUCvDvo7dBVYsPMRZHlNWZiD4sAHYcZbd6SwZ2Sy5MOOa2gZlayqhWTxZhydPZnpEJRjpDXV38kgLYQtx0pcr3hseI5docm+PIaDmN2wQKH1/HGA/9FT/fPhA2YGTgBTCjsf8zNpi2Rn5a54+a9mY2UFyTSW94xU76EGLC8ujS6RtgIZcfo2ieiF+g6f5kIpqIpU4D/+fypoEyiQ8lggPluRkh3PxGaDvhQF71Wl9ZmxGw9PAiQakOFGzu+PuL/33hsbMwPkcyxIAPAnpyZZKTZT1rBDzK0kyc2z2HHg66RR1GNCMwWjvzLruv+ReQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=48OAVczOPeEXT4UjekR2QYNoE/zGnjRZkD7iPTlopcA=; b=O1iyO8fwIwb1FtxvHzhInExynJg4etWCepqpU51skN/1n0k4CmIdzRJ64wUQWQTsPmBOkgrwRsBdk1jxf2J5h3NpQqGiDxs7yaOuiPluS7tH21IcaG8WYWGDSPz2eHtfM3ZLeuETvT/5R5X6HVa4NS0or0hbiC0vUHvHkp5+yhzyEXTCYN9lJZzJRMA+ukjEbVL6PEiYPVC93wcGNiyEfO2KwXJg5dFacDklMQS0ELeNRXKSUazS2OloBRIHRovUsq6X/HXqUaMUp6afAkB1epuXpiDaMSUjBeGPR4oWOFXGwdD3CDt1Zad6VMR+Z4NNprgLWsPLq3qrOoLOSDjhKA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=gigacodes.de; dmarc=pass action=none header.from=gigacodes.de; dkim=pass header.d=gigacodes.de; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gigacodes.de; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=48OAVczOPeEXT4UjekR2QYNoE/zGnjRZkD7iPTlopcA=; b=QYLNPmKimMHhxW5LV516Ra3kmL8VB1eUruU2A+H0gkjsIbHOeTVjOw9serRYr/fBFr3E6cSrqTmravJKQsCRuHM3dW7GyqvhmFG4wEstJtPPGJNkCwRd8vR6AUw0dSRbyVsisDMcArph2b7TILeltClbCi8ha7elKy8OgMf6xNk= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=gigacodes.de; Received: from PAXPR10MB4734.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:102:12e::15) by PR3PR10MB4110.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:102:a8::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4755.21; Thu, 9 Dec 2021 08:52:52 +0000 Received: from PAXPR10MB4734.EURPRD10.PROD.OUTLOOK.COM ([fe80::d9de:b41b:461d:fb5b]) by PAXPR10MB4734.EURPRD10.PROD.OUTLOOK.COM ([fe80::d9de:b41b:461d:fb5b%8]) with mapi id 15.20.4755.014; Thu, 9 Dec 2021 08:52:52 +0000 From: Fabian Stelzer To: git@vger.kernel.org Cc: =?utf-8?b?w4Z2YXIgQXJuZmrDtnLDsCBCamFybWFzb24=?= , Junio C Hamano , =?utf-8?q?SZEDER_G=C3=A1bor?= , Fabian Stelzer Subject: [PATCH v6 1/9] t/fmt-merge-msg: do not redirect stderr Date: Thu, 9 Dec 2021 09:52:41 +0100 Message-Id: <20211209085249.13587-2-fs@gigacodes.de> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211209085249.13587-1-fs@gigacodes.de> References: <20211208163335.1231795-1-fs@gigacodes.de> <20211209085249.13587-1-fs@gigacodes.de> X-ClientProxiedBy: AS9PR06CA0012.eurprd06.prod.outlook.com (2603:10a6:20b:462::34) To PAXPR10MB4734.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:102:12e::15) MIME-Version: 1.0 Received: from localhost (2003:ea:5820:600:3e55:2984:f78e:8b18) by AS9PR06CA0012.eurprd06.prod.outlook.com (2603:10a6:20b:462::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4755.17 via Frontend Transport; Thu, 9 Dec 2021 08:52:52 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 8fc0af76-42ff-47c1-5ee2-08d9baf1491c X-MS-TrafficTypeDiagnostic: PR3PR10MB4110:EE_ X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:6790; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: HQghRJTqNZoIw/f0tqEdKJhloKyLZn9zmuG078nJaWgEdbZdPEX2xnyb4WlgXU0awciFIwmWgD4J7Jw49UCl7I2m9MtmH+bGd+tbhOxr91FwbXGjQsEbPzJKvlxWAZf6Tigga4jkQNS81tDslOSrUgBZMkUHkVDYe9Uc/HDyEQZDw1Xq+M4QO2vSdLLkAUA/oAl+xhgGO4KkQoarpbWo+TuVKAz5zNS4KcF5ZxFACLORAq9B4rVpWg/zZ4+qnl0SD2eBfYEXDyOLEZrEounPTkp5Zz9DXGuBzaU3OOpr/q1F9yNWhc3e7q8JBSHwNE3Loa90OlT/c0oizEnmjKU+7rXgDxU0mQmz3TgT1SWSVPhK803Fiouw7yNj9HJMNpTBIXFlzikMLKx2V4iGFuiEVv7zOU3hi6/gqCKwuNYIdj3924cCzAqiwC1uKHN8z6L4c1At8bYo6i4kGnO6A09Nb841oG8Y0B4vcSiw4sPtNmUm4CqxyYWL3W2uThoIoM6jMUGJKeli0MqHJnLjyR8X8rME3L7zKLDfNfYpqb6Cvv69ZkFa36hS4zOmJBRPuPgDS/8nCOg1jo3ttkUo6HFdrvh1ZRHR5WMfNbQ/m6UmqGl8IPbY8F2uqYIsxZRfpc44cCWBHVB59jgkoue4dz3hhQ== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PAXPR10MB4734.EURPRD10.PROD.OUTLOOK.COM;PTR:;CAT:NONE;SFS:(4636009)(136003)(346002)(396003)(376002)(39840400004)(366004)(86362001)(36756003)(8676002)(54906003)(8936002)(316002)(6916009)(6496006)(6486002)(508600001)(66946007)(66556008)(66476007)(186003)(4326008)(2616005)(107886003)(2906002)(1076003)(6666004)(83380400001)(38100700002)(5660300002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: FkScndpX2oDu/QvkkFu62JMu5kVjfLufKjR1/2qbcPW5ZyCq0RDmwz1gCXfGG16R6CQiTQGue+yeGgWmpekee4N2I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ChH6dSAXD980rG1ELTVzum/0W6nfYmLfo6u9uSzQxAPia+7JHf1VPGPZXj+FykcJrqiwjA+eh/mIIVfaaUAecFG2QPUGdFiTSAQ1jqPtASZp2sh6PT3d5cTORZNZdVAucqWH2VXp0Mf7lOXmGqPVJhOo0R1PveYtY9ddPDhNFFOolD31PvlkkOXlIQj0kAViLlTuir50FaVQTaV+NRBE5Dur1DyVSNSEC9YbSexbu7rZExe+jIHUQHn013N4ECasVxov9dRLtbAqPLeMqliBptfzpGwZLcZ7IwoxzY8iPGvIaUFC7RkOTMwI5+5suuo956/A21/eHgSVx+xqqil1XSk9r6bPJONiNweFbRvh/YpngNauQUXNQjg7D+v6/nJpUn805es+etT77v5xvbeAvPqkvNzt3UD8qE78VkBOqkJVMjcsoa7C2WjLpLFiHJAjFNnYs7rFXZfzhCxpPQt2OeNNjuhHmavshAtovkG85otmPL39Re5DI0RLCrav/rYzw5w4GlNrNH8jpayLsQyrTDHoR2JxYuWm5RX4ARhq+IGC5nBRKtitxew9XGYUH1aH8obcj6MA== X-OriginatorOrg: gigacodes.de X-MS-Exchange-CrossTenant-Network-Message-Id: 8fc0af76-42ff-47c1-5ee2-08d9baf1491c X-MS-Exchange-CrossTenant-AuthSource: PAXPR10MB4734.EURPRD10.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Dec 2021 08:52:52.7082 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 80e41b3b-ea1f-4dbc-91eb-225a572951fb X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: eSABN8qrryQ4fgt8zW/H/mXeiFdEnvoJDhu9xkVnJN+rQhdKa2OL9QVwdQUJrAFIj2VNQezEOA/F1NxgKLtDzGhAMJJytygK2k5i63Gxwv8= X-MS-Exchange-Transport-CrossTenantHeadersStamped: PR3PR10MB4110 Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org All the GPG and GPGSSH tests are redirecing stdout as well as stderr to `actual` and grep for success/failure over the resulting file. However, no output is printed on stderr and we do not need to include it in the grep. Signed-off-by: Fabian Stelzer --- t/t6200-fmt-merge-msg.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/t/t6200-fmt-merge-msg.sh b/t/t6200-fmt-merge-msg.sh index 06c5fb5615..cc68bba064 100755 --- a/t/t6200-fmt-merge-msg.sh +++ b/t/t6200-fmt-merge-msg.sh @@ -104,7 +104,7 @@ test_expect_success 'message for merging local branch' ' test_expect_success GPG 'message for merging local tag signed by good key' ' git checkout main && git fetch . signed-good-tag && - git fmt-merge-msg <.git/FETCH_HEAD >actual 2>&1 && + git fmt-merge-msg <.git/FETCH_HEAD >actual && grep "^Merge tag ${apos}signed-good-tag${apos}" actual && grep "^# gpg: Signature made" actual && grep "^# gpg: Good signature from" actual @@ -113,7 +113,7 @@ test_expect_success GPG 'message for merging local tag signed by good key' ' test_expect_success GPG 'message for merging local tag signed by unknown key' ' git checkout main && git fetch . signed-good-tag && - GNUPGHOME=. git fmt-merge-msg <.git/FETCH_HEAD >actual 2>&1 && + GNUPGHOME=. git fmt-merge-msg <.git/FETCH_HEAD >actual && grep "^Merge tag ${apos}signed-good-tag${apos}" actual && grep "^# gpg: Signature made" actual && grep -E "^# gpg: Can${apos}t check signature: (public key not found|No public key)" actual @@ -123,7 +123,7 @@ test_expect_success GPGSSH 'message for merging local tag signed by good ssh key test_config gpg.ssh.allowedSignersFile "${GPGSSH_ALLOWED_SIGNERS}" && git checkout main && git fetch . signed-good-ssh-tag && - git fmt-merge-msg <.git/FETCH_HEAD >actual 2>&1 && + git fmt-merge-msg <.git/FETCH_HEAD >actual && grep "${GPGSSH_GOOD_SIGNATURE_TRUSTED}" actual && ! grep "${GPGSSH_BAD_SIGNATURE}" actual ' @@ -132,7 +132,7 @@ test_expect_success GPGSSH 'message for merging local tag signed by unknown ssh test_config gpg.ssh.allowedSignersFile "${GPGSSH_ALLOWED_SIGNERS}" && git checkout main && git fetch . signed-untrusted-ssh-tag && - git fmt-merge-msg <.git/FETCH_HEAD >actual 2>&1 && + git fmt-merge-msg <.git/FETCH_HEAD >actual && grep "${GPGSSH_GOOD_SIGNATURE_UNTRUSTED}" actual && ! grep "${GPGSSH_BAD_SIGNATURE}" actual && grep "${GPGSSH_KEY_NOT_TRUSTED}" actual