Documentation

MailFake
in package
implements Mailer

Interfaces, Classes and Traits

Mailer

Table of Contents

$mailables  : array<string|int, mixed>
All of the mailables that have been sent.
$queuedMailables  : array<string|int, mixed>
All of the mailables that have been queued.
assertNothingQueued()  : void
Assert that no mailables were queued.
assertNothingSent()  : void
Assert that no mailables were sent.
assertNotQueued()  : void
Determine if a mailable was not queued based on a truth-test callback.
assertNotSent()  : void
Determine if a mailable was not sent based on a truth-test callback.
assertQueued()  : void
Assert if a mailable was queued based on a truth-test callback.
assertSent()  : void
Assert if a mailable was sent based on a truth-test callback.
bcc()  : PendingMail
Begin the process of mailing a mailable class instance.
failures()  : array<string|int, mixed>
Get the array of failed recipients.
hasQueued()  : bool
Determine if the given mailable has been queued.
hasSent()  : bool
Determine if the given mailable has been sent.
queue()  : mixed
Queue a new e-mail message for sending.
queued()  : Collection
Get all of the queued mailables matching a truth-test callback.
raw()  : int
Send a new message when only a raw text part.
send()  : void
Send a new message using a view.
sent()  : Collection
Get all of the mailables matching a truth-test callback.
to()  : PendingMail
Begin the process of mailing a mailable class instance.
assertQueuedTimes()  : void
Assert if a mailable was queued a number of times.
assertSentTimes()  : void
Assert if a mailable was sent a number of times.
mailablesOf()  : Collection
Get all of the mailed mailables for a given type.
queuedMailablesOf()  : Collection
Get all of the mailed mailables for a given type.

Properties

$mailables

All of the mailables that have been sent.

protected array<string|int, mixed> $mailables = []

$queuedMailables

All of the mailables that have been queued.

protected array<string|int, mixed> $queuedMailables = []

Methods

assertNothingQueued()

Assert that no mailables were queued.

public assertNothingQueued() : void
Return values
void

assertNothingSent()

Assert that no mailables were sent.

public assertNothingSent() : void
Return values
void

assertNotQueued()

Determine if a mailable was not queued based on a truth-test callback.

public assertNotQueued(string $mailable[, callable|null $callback = null ]) : void
Parameters
$mailable : string
$callback : callable|null = null
Return values
void

assertNotSent()

Determine if a mailable was not sent based on a truth-test callback.

public assertNotSent(string $mailable[, callable|null $callback = null ]) : void
Parameters
$mailable : string
$callback : callable|null = null
Return values
void

assertQueued()

Assert if a mailable was queued based on a truth-test callback.

public assertQueued(string $mailable[, callable|int|null $callback = null ]) : void
Parameters
$mailable : string
$callback : callable|int|null = null
Return values
void

assertSent()

Assert if a mailable was sent based on a truth-test callback.

public assertSent(string $mailable[, callable|int|null $callback = null ]) : void
Parameters
$mailable : string
$callback : callable|int|null = null
Return values
void

bcc()

Begin the process of mailing a mailable class instance.

public bcc(mixed $users) : PendingMail
Parameters
$users : mixed
Return values
PendingMail

failures()

Get the array of failed recipients.

public failures() : array<string|int, mixed>
Return values
array<string|int, mixed>

hasQueued()

Determine if the given mailable has been queued.

public hasQueued(string $mailable) : bool
Parameters
$mailable : string
Return values
bool

hasSent()

Determine if the given mailable has been sent.

public hasSent(string $mailable) : bool
Parameters
$mailable : string
Return values
bool

queue()

Queue a new e-mail message for sending.

public queue(string|array<string|int, mixed> $view[, string|null $queue = null ]) : mixed
Parameters
$view : string|array<string|int, mixed>
$queue : string|null = null
Return values
mixed

queued()

Get all of the queued mailables matching a truth-test callback.

public queued(string $mailable[, callable|null $callback = null ]) : Collection
Parameters
$mailable : string
$callback : callable|null = null
Return values
Collection

raw()

Send a new message when only a raw text part.

public raw(string $text, Closure|string $callback) : int
Parameters
$text : string
$callback : Closure|string
Return values
int

send()

Send a new message using a view.

public send(string|array<string|int, mixed> $view[, array<string|int, mixed> $data = [] ][, Closure|string $callback = null ]) : void
Parameters
$view : string|array<string|int, mixed>
$data : array<string|int, mixed> = []
$callback : Closure|string = null
Return values
void

sent()

Get all of the mailables matching a truth-test callback.

public sent(string $mailable[, callable|null $callback = null ]) : Collection
Parameters
$mailable : string
$callback : callable|null = null
Return values
Collection

to()

Begin the process of mailing a mailable class instance.

public to(mixed $users) : PendingMail
Parameters
$users : mixed
Return values
PendingMail

assertQueuedTimes()

Assert if a mailable was queued a number of times.

protected assertQueuedTimes(string $mailable[, int $times = 1 ]) : void
Parameters
$mailable : string
$times : int = 1
Return values
void

assertSentTimes()

Assert if a mailable was sent a number of times.

protected assertSentTimes(string $mailable[, int $times = 1 ]) : void
Parameters
$mailable : string
$times : int = 1
Return values
void

mailablesOf()

Get all of the mailed mailables for a given type.

protected mailablesOf(string $type) : Collection
Parameters
$type : string
Return values
Collection

queuedMailablesOf()

Get all of the mailed mailables for a given type.

protected queuedMailablesOf(string $type) : Collection
Parameters
$type : string
Return values
Collection

Search results