final class DefineDatabase implements Actionable, AfterEach, BeforeEach

Calls a test method for database setup with deferred execution support.

Resets RefreshDatabaseState before and after each test.

Methods

__construct(string $method, bool $defer = true)

Construct a new attribute.

void
beforeEach(Application $app)

Handle the attribute before each test.

void
afterEach(Application $app)

Handle the attribute after each test.

mixed
handle(Application $app, Closure $action)

Handle the attribute.

Details

at line 25
__construct(string $method, bool $defer = true)

Construct a new attribute.

Parameters

string $method
bool $defer

at line 34
void beforeEach(Application $app)

Handle the attribute before each test.

Parameters

Application $app

Return Value

void

at line 42
void afterEach(Application $app)

Handle the attribute after each test.

Parameters

Application $app

Return Value

void

at line 52
mixed handle(Application $app, Closure $action)

Handle the attribute.

Parameters

Application $app
Closure $action

Return Value

mixed