From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: X-Spam-Status: No, score=-4.2 required=3.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF shortcircuit=no autolearn=ham autolearn_force=no version=3.4.6 Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id 89F961F640 for ; Sun, 29 Jan 2023 22:58:36 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=80x24.org; s=selector1; t=1675033116; bh=SW5M0SZFSPUhtumKOpeK/XhXAH8IFJ1UPcaEESR/ntQ=; h=From:To:Subject:Date:In-Reply-To:References:From; b=m/0GyM8RuQcw8zVEIDkNwBAbyLfbBcz5t+l5KcLV4PtTy+9vSDepXNzhh9mhQF1tk 89Dn8GO15M5e77EaAnH8/6c31epiqknp4VJs8UX2PCIXUasHsMZUgLxgEw4feAwB6N 13RMU5z2KY4BfngJDOEaOrMIYoSCeFiSx2O/ZWKw= From: Eric Wong To: meta@public-inbox.org Subject: [PATCH 2/2] xt/lei-auth-fail: use valid label name Date: Sun, 29 Jan 2023 22:58:35 +0000 Message-Id: <20230129225835.2830152-3-e@80x24.org> In-Reply-To: <20230129225835.2830152-1-e@80x24.org> References: <20230129225835.2830152-1-e@80x24.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: Uppercase characters aren't allowed for labels due to Xapian boolean limitations, so we need to use lowercase labels. Fixes: 27015c3365fd0690 (lei_input: disallow uppercase characters for labels, 2021-10-31) --- xt/lei-auth-fail.t | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/xt/lei-auth-fail.t b/xt/lei-auth-fail.t index 06cb8533..1ccc2ab2 100644 --- a/xt/lei-auth-fail.t +++ b/xt/lei-auth-fail.t @@ -1,7 +1,8 @@ #!perl -w -# Copyright (C) 2021 all contributors +# Copyright (C) all contributors # License: AGPL-3.0+ -use strict; use v5.10.1; use PublicInbox::TestCommon; +use v5.12; +use PublicInbox::TestCommon; require_mods(qw(Mail::IMAPClient lei)); # TODO: mock IMAP server which fails at authentication so we don't @@ -13,7 +14,7 @@ test_lei(sub { for my $pfx ([qw(q z:0.. --only), "$ro_home/t1", '-o'], [qw(convert -o mboxrd:/dev/stdout)], [qw(convert t/utf8.eml -o), $imap_fail], - ['import'], [qw(tag +L:INBOX)]) { + ['import'], [qw(tag +L:inbox)]) { ok(!lei(@$pfx, $imap_fail), "IMAP auth failure on @$pfx"); like($lei_err, qr!\bE:.*?imaps?://.*?!sm, 'error shown'); unlike($lei_err, qr!Hunter2!s, 'password not shown');