You are here

public function TestSubContext::iWaitForAjax in Panopoly 8.2

Same name and namespace in other branches
  1. 7 modules/panopoly/panopoly_test/behat/steps/panopoly_test.behat.inc \TestSubContext::iWaitForAjax()

Wait for AJAX to finish.

@Given I wait for AJAX

1 call to TestSubContext::iWaitForAjax()
TestSubContext::afterStepWaitForJavascript in modules/panopoly/panopoly_test/behat/steps/panopoly_test.behat.inc
After every step, we want to wait for AJAX loading to finish.

File

modules/panopoly/panopoly_test/behat/steps/panopoly_test.behat.inc, line 652
Provide Behat step-definitions for generic Panopoly tests.

Class

TestSubContext
Behat sub-context for Panopoly.

Code

public function iWaitForAjax() {
  $this
    ->getSession()
    ->wait(5000, 'typeof jQuery !== "undefined" && jQuery.active === 0');
}