protected function EmailTest::getNotifier in Message Notify 8
Constructs an email notifier.
Parameters
\Drupal\message\MessageInterface $message: (optional) The message to construct the notifier with.
Return value
\Drupal\message_notify\Plugin\Notifier\Email The email notifier plugin.
3 calls to EmailTest::getNotifier()
- EmailTest::testSend in tests/
src/ Unit/ Plugin/ Notifier/ EmailTest.php - Test the send method.
- EmailTest::testSendNoEmail in tests/
src/ Unit/ Plugin/ Notifier/ EmailTest.php - Test sending without an email.
- EmailTest::testSendNoMessage in tests/
src/ Unit/ Plugin/ Notifier/ EmailTest.php - Test sending without a message.
File
- tests/
src/ Unit/ Plugin/ Notifier/ EmailTest.php, line 153
Class
- EmailTest
- Unit tests for the Email notifier.
Namespace
Drupal\Tests\message_notify\Unit\Plugin\NotifierCode
protected function getNotifier(MessageInterface $message = NULL) {
$logger = $this
->prophesize(LoggerChannelInterface::class)
->reveal();
return new Email($this->configuration, $this->pluginId, $this->pluginDefinition, $logger, $this->entityTypeManager, $this->renderer, $message, $this->mailManager);
}