Add public keyword to methods

[MAILPOET-2413]
This commit is contained in:
Amine Ben hammou
2019-12-26 12:56:49 +01:00
committed by wxa
parent ec409042d5
commit 43df66d162
823 changed files with 4440 additions and 4440 deletions

View File

@ -12,7 +12,7 @@ class PHPMailMapperTest extends \MailPoetUnitTest {
/** @var PHPMailMapper*/
private $mapper;
function _before() {
public function _before() {
parent::_before();
$this->mapper = new PHPMailMapper();
WPFunctions::set(Stub::make(new WPFunctions, [
@ -22,26 +22,26 @@ class PHPMailMapperTest extends \MailPoetUnitTest {
]));
}
function testGetProperErrorForSubscriber() {
public function testGetProperErrorForSubscriber() {
$error = $this->mapper->getErrorForSubscriber('john@rambo.com');
expect($error->getLevel())->equals(MailerError::LEVEL_HARD);
expect($error->getMessage())->equals('PHPMail has returned an unknown error.');
expect($error->getSubscriberErrors()[0]->getEmail())->equals('john@rambo.com');
}
function testGetProperErrorFromException() {
public function testGetProperErrorFromException() {
$error = $this->mapper->getErrorFromException(new \Exception('Some message'), 'john@rambo.com');
expect($error->getLevel())->equals(MailerError::LEVEL_HARD);
expect($error->getMessage())->equals('Some message');
expect($error->getSubscriberErrors()[0]->getEmail())->equals('john@rambo.com');
}
function testGetSoftErrorFromExceptionForInvalidEmail() {
public function testGetSoftErrorFromExceptionForInvalidEmail() {
$error = $this->mapper->getErrorFromException(new \Exception('Invalid address. (Add ...'), 'john@rambo.com');
expect($error->getLevel())->equals(MailerError::LEVEL_SOFT);
}
function _after() {
public function _after() {
WPFunctions::set(new WPFunctions);
}
}