Class Horde_Mail_Transport_Mock
Mock implementation, for testing.
-
Horde_Mail_Transport
-
Horde_Mail_Transport_Mock
Methods summary
public
|
#
__construct( array $params = array() )
Constructor.
Parameters
- $params
- <p>parameters:
- postSendCallback: (callback) Called after an email would have been
sent.
- preSendCallback: (callback) Called before an email would be sent.</p>
|
public
|
#
send( mixed $recipients, array $headers, mixed $body )
Send a message. Silently discards all mail.
Send a message. Silently discards all mail.
Parameters
- $recipients
- <p>Either a comma-seperated list of recipients
(RFC822 compliant), or an array of
recipients, each RFC822 valid. This may
contain recipients not specified in the
headers, for Bcc:, resending messages, etc.</p>
- $headers
- <p>The headers to send with the mail, in an
associative array, where the array key is the
header name (ie, 'Subject'), and the array
value is the header value (ie, 'test'). The
header produced from those values would be
'Subject: test'.
If the '_raw' key exists, the value of this
key will be used as the exact text for
sending the message.</p>
- $body
- <p>The full text of the message body, including
any Mime parts, etc. Either a string or a
stream resource.</p>
Throws
|
Properties summary
public
array
|
$sentMessages
Array of messages that have been sent with the mock.
Array of messages that have been sent with the mock.
|
|