From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-Status: No, score=-4.0 required=3.0 tests=ALL_TRUSTED,BAYES_00 shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id 2DB881F9FE for ; Tue, 9 Feb 2021 08:09:38 +0000 (UTC) From: Eric Wong To: meta@public-inbox.org Subject: [PATCH 02/11] test_common: disable fsync on the CLI where possible Date: Tue, 9 Feb 2021 07:09:28 -0100 Message-Id: <20210209080937.4678-3-e@80x24.org> In-Reply-To: <20210209080937.4678-1-e@80x24.org> References: <20210209080937.4678-1-e@80x24.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: This makes tests faster for users on slow TMPDIR (or not using eatmydata) and forces coverage on a non-default switch. Unfortunately, this doesn't yet cover InboxWritable usage. --- lib/PublicInbox/TestCommon.pm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/PublicInbox/TestCommon.pm b/lib/PublicInbox/TestCommon.pm index 2f4ca622..ec9191b6 100644 --- a/lib/PublicInbox/TestCommon.pm +++ b/lib/PublicInbox/TestCommon.pm @@ -269,6 +269,9 @@ sub run_script ($;$$) { die "unable to deal with $ref $redir"; } } + if ($key =~ /-(index|convert|extindex|convert|xcpdb)\z/) { + unshift @argv, '--no-fsync'; + } if ($run_mode == 0) { # spawn an independent new process, like real-world use cases: require PublicInbox::Spawn;