Disable email notifications by default in tests
[MAILPOET-2209]
This commit is contained in:
@ -21,6 +21,7 @@ class Settings {
|
||||
$this->withSender('admin', 'wp@example.com');
|
||||
$this->withSkippedTutorials();
|
||||
$this->withCookieRevenueTracking();
|
||||
$this->withEmailNotificationsDisabled();
|
||||
}
|
||||
|
||||
function withCronTriggerMethod($method) {
|
||||
@ -33,6 +34,12 @@ class Settings {
|
||||
$this->settings->set('sender.address', $address);
|
||||
}
|
||||
|
||||
function withEmailNotificationsDisabled() {
|
||||
$this->settings->set('stats_notifications.enabled', 0);
|
||||
$this->settings->set('subscriber_email_notification.enabled', 0);
|
||||
return $this;
|
||||
}
|
||||
|
||||
function withConfirmationEmailSubject($subject = null) {
|
||||
if ($subject === null) {
|
||||
$subject = sprintf('Confirm your subscription to %1$s', get_option('blogname'));
|
||||
|
Reference in New Issue
Block a user