You are here

public function FormManipulationTrait::check in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/jcalderonzumba/mink-phantomjs-driver/src/FormManipulationTrait.php \Zumba\Mink\Driver\FormManipulationTrait::check()

We click on the checkbox or radio when possible and needed

Parameters

string $xpath:

Throws

DriverException

File

vendor/jcalderonzumba/mink-phantomjs-driver/src/FormManipulationTrait.php, line 117

Class

FormManipulationTrait
Trait FormManipulationTrait @package Zumba\Mink\Driver

Namespace

Zumba\Mink\Driver

Code

public function check($xpath) {
  $this
    ->inputCheckableControl($xpath);
  $javascript = $this
    ->javascriptTemplateRender("check_element.js.twig", array(
    "xpath" => $xpath,
    "check" => "true",
  ));
  $this->browser
    ->evaluate($javascript);
}