qpsmtpd/t/plugin_tests/auth/authdeny
Matt Simerson b00f4c7793 initial import - based on my qpsmtpd fork
which will merge into the main branch fairly easily
2012-06-22 05:38:01 -04:00

15 lines
379 B
Perl

#!perl -w
sub register_tests {
my $self = shift;
$self->register_test("test_authdeny", 1);
}
sub test_authdeny {
my $self = shift;
my $address = Qpsmtpd::Address->parse('<me@example.com>');
my ($ret, $note) = $self->hook_auth($self->qp->transaction, 'bogus_method',
'bogus_user');
is ($ret, DECLINED, "bogus_user is not free to abuse my relay");
}