Main Koha release repository https://koha-community.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

16 lines
480 B

use Modern::Perl;
use t::lib::Mocks;
use Test::More tests => 4; # last test to print
use_ok('Koha::Email');
my $from = 'chrisc@catalyst.net.nz';
t::lib::Mocks::mock_preference('ReplytoDefault', $from);
t::lib::Mocks::mock_preference('ReturnpathDefault', $from);
ok( my $email = Koha::Email->new(), 'Create a Koha::Email Object');
ok( my %mail = $email->create_message_headers({from => $from}),'Set headers');
is ($mail{'From'}, $from, 'Set correctly');