Don't try to use the mail() function if it's not available, should fix Travis-CI builds.
This commit is contained in:
parent
dfc40d56ce
commit
8ad881fb30
|
|
@ -931,13 +931,15 @@ EOT;
|
|||
*/
|
||||
function test_MailSend()
|
||||
{
|
||||
$this->Mail->Body = "Sending via mail()";
|
||||
$this->BuildBody();
|
||||
$subject = $this->Mail->Subject;
|
||||
if (function_exists('mail')) { //Mail is disabled in Travis-CI, so check before trying to use it
|
||||
$this->Mail->Body = "Sending via mail()";
|
||||
$this->BuildBody();
|
||||
$subject = $this->Mail->Subject;
|
||||
|
||||
$this->Mail->Subject = $subject . ": mail()";
|
||||
$this->Mail->IsMail();
|
||||
$this->assertTrue($this->Mail->Send(), $this->Mail->ErrorInfo);
|
||||
$this->Mail->Subject = $subject . ": mail()";
|
||||
$this->Mail->IsMail();
|
||||
$this->assertTrue($this->Mail->Send(), $this->Mail->ErrorInfo);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in New Issue