Skip to content

Instantly share code, notes, and snippets.

View fadonascimento's full-sized avatar

Fabricio Henrique fadonascimento

View GitHub Profile
@fadonascimento
fadonascimento / gist:6e489b1a4c923bad89c4b6f96712aa78
Created October 30, 2017 18:22
behat selenium wait for steps
class FeatureContext extends MinkContext {
/**
* @Given /^I wait for css element "([^"]+)" to (appear|disappear)$/
*/
public function iWaitForCssElement($element, $appear)
{
$xpath = $this->getSession()->getSelectorsHandler()->selectorToXpath('css', $element);
$this->waitForXpath($xpath, $appear == 'appear');
}