1 simpletest.module simpletest_mail_alter(&$message)

Implements hook_mail_alter().

Aborts sending of messages with ID 'simpletest_cancel_test'.

See also

MailTestCase::testCancelMessage()

File

core/modules/simpletest/simpletest.module, line 627
Provides testing functionality.

Code

function simpletest_mail_alter(&$message) {
  if ($message['id'] == 'simpletest_cancel_test') {
    $message['send'] = FALSE;
  }
}