]> Sergey Matveev's repositories - public-inbox.git/commitdiff
t/config: test --get-urlmatch for git <2.26
authorEric Wong <e@80x24.org>
Sat, 26 Dec 2020 12:30:35 +0000 (12:30 +0000)
committerEric Wong <e@80x24.org>
Sat, 26 Dec 2020 20:20:13 +0000 (20:20 +0000)
While git 1.8.5 learned --get-urlmatch, git did not learn to
match URLs against wildcards until 2.26.  So only depend on
1.8.5 for this test since 2.26 is too new.

Reported-by: Ali Alnubani <alialnu@nvidia.com>
Link: https://public-inbox.org/meta/DM6PR12MB49106F8E3BD697B63B943A22DADB0@DM6PR12MB4910.namprd12.prod.outlook.com/
Tested-by: Ali Alnubani <alialnu@nvidia.com>
(cherry picked from commit 382a2bdd54cfb6c28a935c2b9fe4f1b1c2f469c4)

t/config.t

index ee51c6cc2628d8c663c47a90ab8a3cd12d6d7dc5..204fc79024f10f7da15d254f654adccaae7150ac 100644 (file)
@@ -236,12 +236,13 @@ EOF
 }
 
 SKIP: {
+       # XXX wildcard match requires git 2.26+
        require_git('1.8.5', 2) or
                skip 'git 1.8.5+ required for --url-match', 2;
        my $f = "$tmpdir/urlmatch";
        open my $fh, '>', $f or BAIL_OUT $!;
        print $fh <<EOF or BAIL_OUT $!;
-[imap "imap://*.example.com"]
+[imap "imap://mail.example.com"]
        pollInterval = 9
 EOF
        close $fh or BAIL_OUT;