diff options
author | Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de> | 2016-10-17 00:14:55 +0200 |
---|---|---|
committer | Heiko Schlittermann (HS12-RIPE) <hs@schlittermann.de> | 2016-10-17 00:14:55 +0200 |
commit | c039ce6150634eb51a120406b5b7784823430eb5 (patch) | |
tree | 098b52e6e1f5300a09981846b662c95e3d3d51ed /test/runtest | |
parent | d88f0784c1400a06efb1b09d0bfcfa31c284c7d7 (diff) |
Testsuite: Check version of binary against current git revision
Diffstat (limited to 'test/runtest')
-rwxr-xr-x | test/runtest | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/runtest b/test/runtest index ca3124729..7fe0e5dae 100755 --- a/test/runtest +++ b/test/runtest @@ -2566,6 +2566,17 @@ open(EXIMINFO, "$parm_exim -d -C $parm_cwd/test-config -DDIR=$parm_cwd " . die "** Cannot run $parm_exim: $!\n"; while(<EXIMINFO>) { + if (my ($version) = /^Exim version (\S+)/) { + my $git = `git describe --dirty=-XX --match 'exim-4*'`; + if (defined $git and $? == 0) { + chomp $git; + $version =~ s/^\d+\K\./_/; + $git =~ s/^exim-//i; + $git =~ s/.*-\Kg([[:xdigit:]]+(?:-XX)?)/$1/; + print "\n*** Version mismatch (Exim: $version vs. GIT: $git). ***\n\n" + if not $version eq $git; + } + } $parm_eximuser = $1 if /^exim_user = (.*)$/; $parm_eximgroup = $1 if /^exim_group = (.*)$/; $parm_trusted_config_list = $1 if /^TRUSTED_CONFIG_LIST:.*?"(.*?)"$/; |