function WebAssert::cookieExists
Checks that specified cookie exists.
Parameters
string $name cookie name:
Return value
void
Throws
1 call to WebAssert::cookieExists()
- WebAssert::cookieEquals in vendor/
behat/ mink/ src/ WebAssert.php - Checks that specified cookie exists and its value equals to a given one.
File
-
vendor/
behat/ mink/ src/ WebAssert.php, line 125
Class
- WebAssert
- Mink web assertions tool.
Namespace
Behat\MinkCode
public function cookieExists(string $name) {
$message = sprintf('Cookie "%s" is not set, but should be.', $name);
$this->assert($this->session
->getCookie($name) !== null, $message);
}