protected function WebprofilerTestBase::waitForToolbar in Devel 8.2
Same name and namespace in other branches
- 8.3 webprofiler/tests/src/FunctionalJavascript/WebprofilerTestBase.php \Drupal\Tests\webprofiler\FunctionalJavascript\WebprofilerTestBase::waitForToolbar()
- 8 webprofiler/tests/src/FunctionalJavascript/WebprofilerTestBase.php \Drupal\Tests\webprofiler\FunctionalJavascript\WebprofilerTestBase::waitForToolbar()
- 4.x webprofiler/tests/src/FunctionalJavascript/WebprofilerTestBase.php \Drupal\Tests\webprofiler\FunctionalJavascript\WebprofilerTestBase::waitForToolbar()
Wait until the toolbar is present on page.
3 calls to WebprofilerTestBase::waitForToolbar()
- ToolbarTest::testToolbarNotAppearsOnExcludedPath in webprofiler/
tests/ src/ FunctionalJavascript/ ToolbarTest.php - Tests the toolbar not appears on excluded path.
- ToolbarTest::testToolbarOnFrontPage in webprofiler/
tests/ src/ FunctionalJavascript/ ToolbarTest.php - Tests if the toolbar appears on front page.
- ToolbarTest::testToolbarReportPage in webprofiler/
tests/ src/ FunctionalJavascript/ ToolbarTest.php - Tests the toolbar report page.
File
- webprofiler/
tests/ src/ FunctionalJavascript/ WebprofilerTestBase.php, line 18
Class
- WebprofilerTestBase
- Class WebprofilerTestBase.
Namespace
Drupal\Tests\webprofiler\FunctionalJavascriptCode
protected function waitForToolbar() {
$session = $this
->getSession();
$token = $this
->getToken();
$page = $session
->getPage();
$toolbar = $page
->findById('webprofiler' . $token);
$this
->assertTrue($toolbar
->hasClass('sf-toolbar'), 'Toolbar loader is present in page');
$session
->wait(1000, 'null !== document.getElementById(\'sfToolbarMainContent-' . $token . '\')');
return $token;
}