diff --git a/tests/DataFactories/Settings.php b/tests/DataFactories/Settings.php index 7b70b057c7..09ede191b9 100644 --- a/tests/DataFactories/Settings.php +++ b/tests/DataFactories/Settings.php @@ -18,6 +18,7 @@ class Settings { function withDefaultSettings() { $this->withCronTriggerMethod('WordPress'); $this->withSendingMethodSmtpMailhog(); + $this->withSender('admin', 'wp@example.com'); $this->withSkippedTutorials(); $this->withCookieRevenueTracking(); } @@ -27,6 +28,11 @@ class Settings { return $this; } + function withSender($name, $address) { + $this->settings->set('sender.name', $name); + $this->settings->set('sender.address', $address); + } + function withConfirmationEmailSubject($subject = null) { if ($subject === null) { $subject = sprintf('Confirm your subscription to %1$s', get_option('blogname'));