mirror of
https://github.com/silverstripe/silverstripe-testsession
synced 2024-10-22 14:06:00 +02:00
Merge pull request #83 from creative-commoners/pulls/2/stop-depr
API Stop using deprecated API
This commit is contained in:
commit
ffe1bc8fa2
@ -80,7 +80,6 @@ class TestSessionEnvironment
|
|||||||
|
|
||||||
public function __construct($id = null)
|
public function __construct($id = null)
|
||||||
{
|
{
|
||||||
$this->constructExtensions();
|
|
||||||
if ($id) {
|
if ($id) {
|
||||||
$this->id = $id;
|
$this->id = $id;
|
||||||
}
|
}
|
||||||
|
@ -69,7 +69,7 @@ class TestSessionHTTPMiddleware implements HTTPMiddleware
|
|||||||
$mailer = $testState->mailer;
|
$mailer = $testState->mailer;
|
||||||
Injector::inst()->registerService(new $mailer(), Mailer::class);
|
Injector::inst()->registerService(new $mailer(), Mailer::class);
|
||||||
Email::config()->set("send_all_emails_to", null);
|
Email::config()->set("send_all_emails_to", null);
|
||||||
Email::config()->update('admin_email', 'no-reply@example.com');
|
Email::config()->set('admin_email', 'no-reply@example.com');
|
||||||
}
|
}
|
||||||
|
|
||||||
// Connect to the test session database
|
// Connect to the test session database
|
||||||
|
Loading…
Reference in New Issue
Block a user