Documentation

BrowserKitAssertionsTrait

Ideas borrowed from Laravel Dusk's assertions.

Tags
see
https://laravel.com/docs/5.7/dusk#available-assertions

Table of Contents

Methods

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 $domain = null ][, string $message = '' ]) : void
Parameters
$name : string
$expectedValue : string
$raw : bool = false
$path : string = '/'
$domain : string = null
$message : string = ''

assertBrowserHasCookie()

public static assertBrowserHasCookie(string $name[, string $path = '/' ][, string $domain = null ][, string $message = '' ]) : void
Parameters
$name : string
$path : string = '/'
$domain : string = null
$message : string = ''

assertBrowserNotHasCookie()

public static assertBrowserNotHasCookie(string $name[, string $path = '/' ][, string $domain = null ][, string $message = '' ]) : void
Parameters
$name : string
$path : string = '/'
$domain : string = null
$message : string = ''

assertRequestAttributeValueSame()

public static assertRequestAttributeValueSame(string $name, string $expectedValue[, string $message = '' ]) : void
Parameters
$name : string
$expectedValue : string
$message : string = ''

assertResponseCookieValueSame()

public static assertResponseCookieValueSame(string $name, string $expectedValue[, string $path = '/' ][, string $domain = null ][, string $message = '' ]) : void
Parameters
$name : string
$expectedValue : string
$path : string = '/'
$domain : string = null
$message : string = ''

assertResponseFormatSame()

public static assertResponseFormatSame(string|null $expectedFormat[, string $message = '' ]) : void
Parameters
$expectedFormat : string|null
$message : string = ''

assertResponseHasCookie()

public static assertResponseHasCookie(string $name[, string $path = '/' ][, string $domain = null ][, string $message = '' ]) : void
Parameters
$name : string
$path : string = '/'
$domain : string = null
$message : string = ''

assertResponseHasHeader()

public static assertResponseHasHeader(string $headerName[, string $message = '' ]) : void
Parameters
$headerName : string
$message : string = ''

assertResponseHeaderNotSame()

public static assertResponseHeaderNotSame(string $headerName, string $expectedValue[, string $message = '' ]) : void
Parameters
$headerName : string
$expectedValue : string
$message : string = ''

assertResponseHeaderSame()

public static assertResponseHeaderSame(string $headerName, string $expectedValue[, string $message = '' ]) : void
Parameters
$headerName : string
$expectedValue : string
$message : string = ''

assertResponseIsSuccessful()

public static assertResponseIsSuccessful([string $message = '' ]) : void
Parameters
$message : string = ''

assertResponseIsUnprocessable()

public static assertResponseIsUnprocessable([string $message = '' ]) : void
Parameters
$message : string = ''

assertResponseNotHasCookie()

public static assertResponseNotHasCookie(string $name[, string $path = '/' ][, string $domain = null ][, string $message = '' ]) : void
Parameters
$name : string
$path : string = '/'
$domain : string = null
$message : string = ''

assertResponseNotHasHeader()

public static assertResponseNotHasHeader(string $headerName[, string $message = '' ]) : void
Parameters
$headerName : string
$message : string = ''

assertResponseRedirects()

public static assertResponseRedirects([string $expectedLocation = null ][, int $expectedCode = null ][, string $message = '' ]) : void
Parameters
$expectedLocation : string = null
$expectedCode : int = null
$message : string = ''

assertResponseStatusCodeSame()

public static assertResponseStatusCodeSame(int $expectedCode[, string $message = '' ]) : void
Parameters
$expectedCode : int
$message : string = ''

assertRouteSame()

public static assertRouteSame(string $expectedRoute[, array<string|int, mixed> $parameters = [] ][, string $message = '' ]) : void
Parameters
$expectedRoute : string
$parameters : array<string|int, mixed> = []
$message : string = ''

        
On this page

Search results