BrowserKitAssertionsTrait
Ideas borrowed from Laravel Dusk's assertions.
Tags
Table of Contents
- assertBrowserCookieValueSame() : void
- assertBrowserHasCookie() : void
- assertBrowserNotHasCookie() : void
- assertRequestAttributeValueSame() : void
- assertResponseCookieValueSame() : void
- assertResponseFormatSame() : void
- assertResponseHasCookie() : void
- assertResponseHasHeader() : void
- assertResponseHeaderNotSame() : void
- assertResponseHeaderSame() : void
- assertResponseIsSuccessful() : void
- assertResponseIsUnprocessable() : void
- assertResponseNotHasCookie() : void
- assertResponseNotHasHeader() : void
- assertResponseRedirects() : void
- assertResponseStatusCodeSame() : void
- assertRouteSame() : void
- assertThatForClient() : void
- assertThatForResponse() : void
- getClient() : AbstractBrowser|null
- getRequest() : Request
- getResponse() : Response
Methods
assertBrowserCookieValueSame()
public
static assertBrowserCookieValueSame(string $name, string $expectedValue[, bool $raw = false ][, string $path = '/' ][, string|null $domain = null ][, string $message = '' ]) : void
Parameters
- $name : string
- $expectedValue : string
- $raw : bool = false
- $path : string = '/'
- $domain : string|null = null
- $message : string = ''
Return values
void —assertBrowserHasCookie()
public
static assertBrowserHasCookie(string $name[, string $path = '/' ][, string|null $domain = null ][, string $message = '' ]) : void
Parameters
- $name : string
- $path : string = '/'
- $domain : string|null = null
- $message : string = ''
Return values
void —assertBrowserNotHasCookie()
public
static assertBrowserNotHasCookie(string $name[, string $path = '/' ][, string|null $domain = null ][, string $message = '' ]) : void
Parameters
- $name : string
- $path : string = '/'
- $domain : string|null = null
- $message : string = ''
Return values
void —assertRequestAttributeValueSame()
public
static assertRequestAttributeValueSame(string $name, string $expectedValue[, string $message = '' ]) : void
Parameters
- $name : string
- $expectedValue : string
- $message : string = ''
Return values
void —assertResponseCookieValueSame()
public
static assertResponseCookieValueSame(string $name, string $expectedValue[, string $path = '/' ][, string|null $domain = null ][, string $message = '' ]) : void
Parameters
- $name : string
- $expectedValue : string
- $path : string = '/'
- $domain : string|null = null
- $message : string = ''
Return values
void —assertResponseFormatSame()
public
static assertResponseFormatSame(string|null $expectedFormat[, string $message = '' ]) : void
Parameters
- $expectedFormat : string|null
- $message : string = ''
Return values
void —assertResponseHasCookie()
public
static assertResponseHasCookie(string $name[, string $path = '/' ][, string|null $domain = null ][, string $message = '' ]) : void
Parameters
- $name : string
- $path : string = '/'
- $domain : string|null = null
- $message : string = ''
Return values
void —assertResponseHasHeader()
public
static assertResponseHasHeader(string $headerName[, string $message = '' ]) : void
Parameters
- $headerName : string
- $message : string = ''
Return values
void —assertResponseHeaderNotSame()
public
static assertResponseHeaderNotSame(string $headerName, string $expectedValue[, string $message = '' ]) : void
Parameters
- $headerName : string
- $expectedValue : string
- $message : string = ''
Return values
void —assertResponseHeaderSame()
public
static assertResponseHeaderSame(string $headerName, string $expectedValue[, string $message = '' ]) : void
Parameters
- $headerName : string
- $expectedValue : string
- $message : string = ''
Return values
void —assertResponseIsSuccessful()
public
static assertResponseIsSuccessful([string $message = '' ]) : void
Parameters
- $message : string = ''
Return values
void —assertResponseIsUnprocessable()
public
static assertResponseIsUnprocessable([string $message = '' ]) : void
Parameters
- $message : string = ''
Return values
void —assertResponseNotHasCookie()
public
static assertResponseNotHasCookie(string $name[, string $path = '/' ][, string|null $domain = null ][, string $message = '' ]) : void
Parameters
- $name : string
- $path : string = '/'
- $domain : string|null = null
- $message : string = ''
Return values
void —assertResponseNotHasHeader()
public
static assertResponseNotHasHeader(string $headerName[, string $message = '' ]) : void
Parameters
- $headerName : string
- $message : string = ''
Return values
void —assertResponseRedirects()
public
static assertResponseRedirects([string|null $expectedLocation = null ][, int|null $expectedCode = null ][, string $message = '' ]) : void
Parameters
- $expectedLocation : string|null = null
- $expectedCode : int|null = null
- $message : string = ''
Return values
void —assertResponseStatusCodeSame()
public
static assertResponseStatusCodeSame(int $expectedCode[, string $message = '' ]) : void
Parameters
- $expectedCode : int
- $message : string = ''
Return values
void —assertRouteSame()
public
static assertRouteSame(string $expectedRoute[, array<string|int, mixed> $parameters = [] ][, string $message = '' ]) : void
Parameters
- $expectedRoute : string
- $parameters : array<string|int, mixed> = []
- $message : string = ''
Return values
void —assertThatForClient()
public
static assertThatForClient(Constraint $constraint[, string $message = '' ]) : void
Parameters
- $constraint : Constraint
- $message : string = ''
Return values
void —assertThatForResponse()
public
static assertThatForResponse(Constraint $constraint[, string $message = '' ]) : void
Parameters
- $constraint : Constraint
- $message : string = ''
Return values
void —getClient()
private
static getClient([AbstractBrowser|null $newClient = null ]) : AbstractBrowser|null
Parameters
- $newClient : AbstractBrowser|null = null
Return values
AbstractBrowser|null —getRequest()
private
static getRequest() : Request
Return values
Request —getResponse()
private
static getResponse() : Response