Phil Howard ttiphil@gmail.com (Di 18 Mai 2010 16:04:14 CEST):
I'm looking for an IMAP testing tool, suitable to use with Dovecot IMAP. It needs to support TLS, STARTTLS, and login/authentication. It needs to be able run from command line, shell scripts, and even do so under cron jobs (e.g. a way to supply the password to use w/o a terminal prompt). Typical interactive mail clients just don't cut it (even the text mode ones). One reason is I need to do the tests on a number of machines, under a number of user and domain names, and with a variety of parameters or destinations. This is for a suite of regression tests I am putting together intended to verify that configuration changes do not break things (or unbreak things that are supposed to not work).
Anyone ever heard of such a tool? Open source would be preferred (better yet, my favorite programming languages: C, Pike, Python).
You could use imtest and pop3test from the cyrus suite. The newer versions should work with a dovecot server too. (Older ones were buggy and expected more output than dovecot sent.)
For Perl exist several modules/libray to home brew your tests.
use Mail::IMAPClient;
my $s = new Mail::IMAPCLient(
Server => …,
User => …,
…
) or die $@;
$s->examine("INBOX") or die $@;
… and so on.
-- Heiko