class Illuminate / Testing / ParallelTesting
You're browsing the documentation for an upcoming version of Laravel. The documentation and features of this release are subject to change.

ParallelTesting

Properties

protected

$container Container

The container instance.

Default: null
protected

$optionsResolver Closure |null

The options resolver callback.

Default: null
protected

$tokenResolver Closure |null

The token resolver callback.

Default: null
protected

$setUpProcessCallbacks array

All of the registered "setUp" process callbacks.

Default: []
protected

$setUpTestCaseCallbacks array

All of the registered "setUp" test case callbacks.

Default: []
protected

$setUpTestDatabaseCallbacks array

All of the registered "setUp" test database callbacks.

Default: []
protected

$tearDownProcessCallbacks array

All of the registered "tearDown" process callbacks.

Default: []
protected

$tearDownTestCaseCallbacks array

All of the registered "tearDown" test case callbacks.

Default: []

Methods

public

__construct ( Container $container ) : void

Create a new parallel testing instance.

Parameters

public

resolveOptionsUsing ( $resolver ) : void

Set a callback that should be used when resolving options.

Parameters

public

resolveTokenUsing ( $resolver ) : void

Set a callback that should be used when resolving the unique process token.

Parameters

public

setUpProcess ( $callback ) : void

Register a "setUp" process callback.

Parameters

  • $callback callable
public

setUpTestCase ( $callback ) : void

Register a "setUp" test case callback.

Parameters

  • $callback callable
public

setUpTestDatabase ( $callback ) : void

Register a "setUp" test database callback.

Parameters

  • $callback callable
public

tearDownProcess ( $callback ) : void

Register a "tearDown" process callback.

Parameters

  • $callback callable
public

tearDownTestCase ( $callback ) : void

Register a "tearDown" test case callback.

Parameters

  • $callback callable
public

callSetUpProcessCallbacks ( ) : void

Call all of the "setUp" process callbacks.

public

callSetUpTestCaseCallbacks ( $testCase ) : void

Call all of the "setUp" test case callbacks.

Parameters

public

callSetUpTestDatabaseCallbacks ( $database ) : void

Call all of the "setUp" test database callbacks.

Parameters

  • $database string
public

callTearDownProcessCallbacks ( ) : void

Call all of the "tearDown" process callbacks.

public

callTearDownTestCaseCallbacks ( $testCase ) : void

Call all of the "tearDown" test case callbacks.

Parameters

public

option ( $option ) : mixed

Get a parallel testing option.

Parameters

  • $option string
public

token ( ) : string|false

Gets a unique test token.

protected

whenRunningInParallel ( $callback ) : void

Apply the callback if tests are running in parallel.

Parameters

  • $callback callable
protected

inParallel ( ) : bool

Indicates if the current tests are been run in parallel.