protected function EntityUsageJavascriptTestBase::waitUntilVisible in Entity Usage 8.3
Same name and namespace in other branches
- 8.4 tests/src/FunctionalJavascript/EntityUsageJavascriptTestBase.php \Drupal\Tests\entity_usage\FunctionalJavascript\EntityUsageJavascriptTestBase::waitUntilVisible()
- 8 tests/src/FunctionalJavascript/EntityUsageJavascriptTestBase.php \Drupal\Tests\entity_usage\FunctionalJavascript\EntityUsageJavascriptTestBase::waitUntilVisible()
- 8.2 tests/src/FunctionalJavascript/EntityUsageJavascriptTestBase.php \Drupal\Tests\entity_usage\FunctionalJavascript\EntityUsageJavascriptTestBase::waitUntilVisible()
Waits and asserts that a given element is visible.
Parameters
string $selector: The CSS selector.
int $timeout: (Optional) Timeout in milliseconds, defaults to 2000.
string $message: (Optional) Message to pass to assertJsCondition().
File
- tests/
src/ FunctionalJavascript/ EntityUsageJavascriptTestBase.php, line 60
Class
- EntityUsageJavascriptTestBase
- Base class for Entity Usage Javascript functional tests.
Namespace
Drupal\Tests\entity_usage\FunctionalJavascriptCode
protected function waitUntilVisible($selector, $timeout = 2000, $message = '') {
$condition = "jQuery('" . $selector . ":visible').length > 0";
$this
->assertJsCondition($condition, $timeout, $message);
}