use Time::Local;
use Cwd;
use File::Basename;
+use FindBin qw'$Bin';
+
+use lib "$Bin/lib";
+use Exim::Runtest;
+
use if $ENV{DEBUG} && $ENV{DEBUG} =~ /\bruntest\b/ => ('Smart::Comments' => '####');
$parm_port_d4 = 1228; # Additional for daemon
my $dynamic_socket; # allocated later for PORT_DYNAMIC
+# Find a suiteable group name for test (currently only 0001
+# uses a group name. A numeric group id would do
+my $parm_mailgroup = Exim::Runtest::mailgroup('mail');
+
# Manually set locale
$ENV{LC_ALL} = 'C';
s?(\b|_)V4NET([\._])?$1$parm_ipv4_test_net$2?g;
s?\bV6NET:?$parm_ipv6_test_net:?g;
s?\bPORT_DYNAMIC\b?$dynamic_socket->sockport()?eg;
+s?\bMAILGROUP\b?$parm_mailgroup?g;
}
# contains ****. We open input from the terminal so that we can read responses
# to prompts.
-open(T, "/dev/tty") || tests_exit(-1, "Failed to open /dev/tty: $!");
+if (not $force_continue) {
+ # runtest needs to interact if we're not in continue
+ # mode. It does so by communicate to /dev/tty
+ open(T, "/dev/tty") or tests_exit(-1, "Failed to open /dev/tty: $!");
+}
+
print "\nPress RETURN to run the tests: ";
$_ = $force_continue ? "c" : <T>;