#use strict;
use v5.10.1;
use warnings;
-use if $^V >= v5.19.11, experimental => 'smartmatch';
use Errno;
use FileHandle;
s/250-AUTH ANONYMOUS PLAIN SCRAM-SHA-1\K SCRAM-SHA-256//;
# mailq times change with when the run is done, vs. static-source spoolfiles
- s/\s*\d*[hd](?= 317 [0-9A-Za-z\-]{23} <nobody\@test.ex>)/DDd/;
+ s/\s*\d*[hd](?= 317 (?:[-0-9A-Za-z]{23}|[-0-9A-Za-z]{16}) <nobody\@test.ex>)/DDd/;
+ # mailq sizes change with caller running the test
+ s/\s[01]m [34]\d\d(?= (?:[-0-9A-Za-z]{23}|[-0-9A-Za-z]{16}) <CALLER\@the.local.host.name>)/ 1m 396/;
# Not all builds include EXPERIMENTAL_DSN_INFO (1 of 2)
if (/^X-Exim-Diagnostic:/)
next if / Berkeley DB error: /;
# CHUNKING: exact sizes depend on hostnames in headers
- s/(=>.* K C="250- \d)\d+ (byte chunk, total \d)\d+/$1nn $2nn/;
+ s/(=>.* K (?:DKIM=\S+ )?C="250- \d)\d+ (byte chunk, total \d)\d+/$1nn $2nn/;
# OpenSSL version variances
s/(TLS error on connection [^:]*: error:)[0-9A-F]{8}(:system library):(?:fopen|func\(4095\)|):(No such file or directory)$/$1xxxxxxxx$2:fopen:$3/;
s/ARC: AMS signing: privkey PEM-block import: error:\K[0-9A-F]{8}:PEM routines:PEM_read_bio:no start line$/1E08010C:DECODER routines::unsupported/;
# DKIM timestamps
- if ( /(DKIM: d=.*) t=([0-9]*) x=([0-9]*) / )
+ if ( /(DKIM: d=.*) t=([0-9]*) x=([0-9]*) \[/ )
{
my ($prefix, $t_diff) = ($1, $3 - $2);
s/DKIM: d=.* t=[0-9]* x=[0-9]* /${prefix} t=T x=T+${t_diff} /;
}
+ else
+ { s/DKIM: d=.* \Kt=[0-9]* \[/t=T [/; }
# GnuTLS reports a different keysize vs. OpenSSL, for ed25519 keys
s/signer: [^ ]* bits:\K 256/ 253/;
s/public key too short:\K 256 bits/ 253 bits/;
<IN>;
<IN>;
}
+ elsif ( /^(\s+)t=([0-9]*); b=[A-Za-z0-9+\/]+$/ )
+ {
+ my $indent = $1;
+ s/.*/${indent}t=T; b=bbbb;/;
+ <IN>;
+ <IN>;
+ }
# Not all builds include EXPERIMENTAL_DSN_INFO (2 of 2)
if (/^X-Exim-Diagnostic:/)
print "Exim binary is `$parm_exim'\n" if defined $parm_exim;
+my %wanted;
my @wanted = sort numerically uniq
@tests_wanted ? @tests_wanted : (),
@range_wanted ? $range_wanted[0] .. $range_wanted[1] : (),
0+$ARGV[0]..0+$ARGV[1] # add 0 to cope with test numbers starting with zero
: ();
@wanted = 1..TEST_TOP if not @wanted;
+map { $wanted{sprintf("%04d",$_)}= $_; } @wanted;
##################################################
# Check for sudo access to root #
# We want the tests from this subdirectory, provided they are in the
# range that was selected.
- @testlist = grep { $_ ~~ @wanted } grep { /^\d+(?:\.\d+)?$/ } map { basename $_ } glob "scripts/$testdir/*";
+ undef @testlist;
+ map { push @testlist, $_ if exists $wanted{$_} } grep { /^\d+(?:\.\d+)?$/ } map { basename $_ } glob "scripts/$testdir/*";
tests_exit(-1, "Failed to read test scripts from `scripts/$testdir/*': $!")
if not @testlist;