You are here

public function VarbaseContext::iWaitForSeconds in Varbase: The Ultimate Drupal CMS Starter Kit (Bootstrap Ready) 8.5

Same name and namespace in other branches
  1. 8.8 tests/features/bootstrap/VarbaseContext.php \VarbaseContext::iWaitForSeconds()
  2. 8.4 tests/features/bootstrap/VarbaseContext.php \VarbaseContext::iWaitForSeconds()
  3. 8.6 tests/features/bootstrap/VarbaseContext.php \VarbaseContext::iWaitForSeconds()
  4. 8.7 tests/features/bootstrap/VarbaseContext.php \VarbaseContext::iWaitForSeconds()
  5. 9.0.x tests/features/bootstrap/VarbaseContext.php \VarbaseContext::iWaitForSeconds()

#varbase: To wait for seconds before going to the next step.

Example 1: And wait for "1" second Example 2: When I wait for "5" seconds Example 3: And wait 1 second Example 4: When I wait for 60 seconds Example 5: And wait 1s Example 6: When I wait for 60s

@When /^(?:|I )wait (?:|for )"(?P<seconds>\d+)" second(?:|s)$/ @When /^(?:|I )wait (?:|for )(?P<seconds>\d+) second(?:|s)$/ @When /^(?:|I )wait (?:|for )(?P<seconds>\d+)s$/

File

tests/features/bootstrap/VarbaseContext.php, line 141

Class

VarbaseContext
Defines application features from the specific context.

Code

public function iWaitForSeconds($seconds) {
  $this
    ->getSession()
    ->wait($seconds * 1000);
}