You are here

protected function OffCanvasTestBase::assertElementVisibleAfterWait in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/system/tests/src/FunctionalJavascript/OffCanvasTestBase.php \Drupal\Tests\system\FunctionalJavascript\OffCanvasTestBase::assertElementVisibleAfterWait()

Asserts the specified selector is visible after a wait.

Parameters

string $selector: The selector engine name. See ElementInterface::findAll() for the supported selectors.

string|array $locator: The selector locator.

int $timeout: (Optional) Timeout in milliseconds, defaults to 10000.

7 calls to OffCanvasTestBase::assertElementVisibleAfterWait()
ConfigAccessTest::testBlockConfigAccess in core/modules/settings_tray/tests/src/FunctionalJavascript/ConfigAccessTest.php
Tests access to block forms with related configuration is correct.
OffCanvasTestBase::waitForOffCanvasToOpen in core/modules/system/tests/src/FunctionalJavascript/OffCanvasTestBase.php
Waits for off-canvas dialog to open.
OverriddenConfigurationTest::testOverriddenConfigurationRemoved in core/modules/settings_tray/tests/src/FunctionalJavascript/OverriddenConfigurationTest.php
Tests blocks with overridden related configuration removed when overridden.
SettingsTrayBlockFormTest::doTestBlocks in core/modules/settings_tray/tests/src/FunctionalJavascript/SettingsTrayBlockFormTest.php
Tests opening off-canvas dialog by click blocks and elements in the blocks.
SettingsTrayIntegrationTest::testQuickEditLinks in core/modules/quickedit/tests/src/FunctionalJavascript/SettingsTrayIntegrationTest.php
Tests QuickEdit links behavior.

... See full list

File

core/modules/system/tests/src/FunctionalJavascript/OffCanvasTestBase.php, line 119

Class

OffCanvasTestBase
Base class contains common test functionality for the Off-canvas dialog.

Namespace

Drupal\Tests\system\FunctionalJavascript

Code

protected function assertElementVisibleAfterWait($selector, $locator, $timeout = 10000) {
  $this
    ->assertSession()
    ->assertWaitOnAjaxRequest();
  $this
    ->assertNotEmpty($this
    ->assertSession()
    ->waitForElementVisible($selector, $locator, $timeout));
}