getinstance/fbwebdriverfacade

A handy facade for common facebook php-webdriver operations

v3.0.0 2023-02-20 16:47 UTC

This package is auto-updated.

Last update: 2024-10-20 20:57:00 UTC


README

An internal tool we use to shortcut various php-webdriver operations - including workarounds for some operations that don't seem to work for us any longer.

Version 1.0.8

use getinstance\fbwebdriverfacade\SeleniumLib;
use Facebook\WebDriver\Remote\WebDriverCapabilityType;
use Facebook\WebDriver\Remote\RemoteWebDriver;

// you'll need the selenium server running

$host = "http://127.0.0.1:7772/wd/hub";
$coreurl = "http://www.google.com";
$capabilities = array(WebDriverCapabilityType::BROWSER_NAME => 'firefox');
$driver = RemoteWebDriver::create($host, $capabilities);
$tools = new SeleniumLib( $driver );
$driver->get($coreurl);

$tools->typeIn("q", "fbwebdriverfacade");
$tools->clickButton("Google Search");
$tools->waitForId("resultStats");
$tools->clickLink("Videos");