You are here

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

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

#varbase: To expand a field group by its id attribute.

Example #1: I expand the field "Field Group ID"

@When I expand the field :arg1

File

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

Class

VarbaseContext
Defines application features from the specific context.

Code

public function iExpandThefield($fieldID) {
  $js = <<<JS
    var group = document.getElementById("{<span class="php-variable">$fieldID</span>}");
    group.setAttribute("open","");
JS;
  $this
    ->getSession()
    ->executeScript($js);
}