You are here

protected function IntegrationTest::assertAlertMessage in Webform Deter 8

Whether there is a JS alert open with the given text.

Parameters

string $text: The text that should contain the alert message.

Return value

bool TRUE if there is an active JS alert with the given text, FALSE otherwise.

1 call to IntegrationTest::assertAlertMessage()
IntegrationTest::testIntegration in tests/src/FunctionalJavascript/IntegrationTest.php
Tests basic webform deter functionality.

File

tests/src/FunctionalJavascript/IntegrationTest.php, line 123

Class

IntegrationTest
Tests basic webform_deter functionality.

Namespace

Drupal\Tests\webform_deter\FunctionalJavascript

Code

protected function assertAlertMessage($text) {
  return $text === $this
    ->getSession()
    ->getDriver()
    ->getWebDriverSession()
    ->getAlert_text();
}