Click on the element with the provided xpath query

@When /^(?:|I )click on the element "([^"]*)"$/
@param $locator
489125
public function iClickOnTheElement($locator)
    {
        $session = $this->getSession(); // get the mink session
        $element = $session->getPage()->find('css', $locator); // runs the actual query and returns the element

        // errors must not pass silently
        PHPUnit_Framework_Assert::assertNotNull($element, sprintf('Could not evaluate CSS selector: "%s"', $locator));

        $this->getSession()->executeScript(
            "$('#" . $element->getAttribute('id') . "').click()"
        );

        // ok, let's click on it
        $element->click();
    }
1179226
public Element newElement(Locator type, String locator) {
        return new Element(driver, reporter, type, locator);
    }
1211587
public function mouseover(string $selector = null): Element
    {
        if ($selector === null) {
            $element = $this->remote;
        } else {
            $element = $this->resolver->findOrFail($selector);
        }

        $this->driver->getMouse()->mouseMove($element->getCoordinates());

        return $this;
    }
1368081
public function rightClick($xpath) {
    $elements = $this->findElement($xpath, 1);
    $this->browser->rightClick($elements["page_id"], $elements["ids"][0]);
  }
64968
public void click() {
    assertElementNotStale();
    assertElementDisplayed();

    parent.getScopeServices().captureOperaIdle();

    if (getTagName().equals("OPTION")) {
      callMethod("return " + OperaAtom.CLICK + "(locator)");
    } else {
      parent.getMouse().click(getCoordinates());
    }

    try {
      parent.waitForLoadToComplete();
    } catch (ResponseNotReceivedException e) {
      // This might be expected
      logger.fine("Response not received, returning control to user");
    }
  }
587774
public function hasCheckedField($locator)
    {
        $field = $this->findField($locator);

        return null !== $field && $field->isChecked();
    }
1258927
public static void waitUntilElementIsPresent(final String elementLocator) {
        logger.entering(elementLocator);
        By by = HtmlElementUtils.resolveByType(elementLocator);
        ExpectedCondition<WebElement> condition = ExpectedConditions.presenceOfElementLocated(by);
        waitForCondition(condition);
        logger.exiting();
    }
828278
public function findElement($strategy, $selector)
	{
		return $this->element($this->using($strategy)->value($selector));
	}
892939
function (/*HTMLElement*/ el) {
		TL.DomEvent.addListener(el, TL.Draggable.START, TL.DomEvent.stopPropagation);
		TL.DomEvent.addListener(el, 'click', TL.DomEvent.stopPropagation);
		TL.DomEvent.addListener(el, 'dblclick', TL.DomEvent.stopPropagation);
	}
1243401
public void click(String locator) {
        getDispatcher().beforeClick(this, locator);
        
        getElement().click();
        validatePresenceOfAlert();
        if (Config.getBoolConfigProperty(ConfigProperty.ENABLE_GUI_LOGGING)) {
            logUIAction(UIActions.CLICKED);
        }
        WebDriverWaitUtils.waitUntilElementIsPresent(locator);
        
        getDispatcher().afterClick(this, locator);
    }
1311761
public function isSelected($xpath) {
    $elements = $this->findElement($xpath, 1);
    $javascript = $this->javascriptTemplateRender("is_selected.js.twig", array("xpath" => $xpath));
    $tagName = $this->browser->tagName($elements["page_id"], $elements["ids"][0]);
    if (strcmp(strtolower($tagName), "option") !== 0) {
      throw new DriverException("Can not assert on element that is not an option");
    }

    return $this->browser->evaluate($javascript);
  }
502047
@SuppressWarnings("unchecked")
    public <T extends XPathBuilder> T setContainer(WebLocator container) {
        this.container = container;
        return (T) this;
    }
1003009
protected function select($value, $element)
    {
        $this->wd->findElement(WebDriverBy::cssSelector($element))->sendKeys($value);

        return $this;
    }
1273390
public static void waitUntilElementIsInvisible(final String elementLocator) {
        logger.entering(elementLocator);
        By by = HtmlElementUtils.resolveByType(elementLocator);
        ExpectedCondition<Boolean> condition = ExpectedConditions.invisibilityOfElementLocated(by);
        waitForCondition(condition);
        logger.exiting();
    }
46373
public function focus($xpath) {
    $element = $this->findElement($xpath, 1);
    $this->browser->trigger($element["page_id"], $element["ids"][0], "focus");
  }
626507
public void mouseHoverOverElement(By locator) {
        SynchronisationService synchronisationService = new SynchronisationService();

        synchronisationService.waitAndAssertForExpectedCondition(ExpectedConditions.visibilityOfElementLocated(locator));

        WebElement element = getWebDriver().findElement(locator);
        Actions builder = new Actions(getWebDriver());
        Actions hoverOverRegistrar = builder.moveToElement(element);
        hoverOverRegistrar.perform();
    }
556483
def click_element(self, locator):
        
        self._info("Clicking element '%s'." % locator)
        self._element_find(locator, True, True).click()