Created
September 20, 2011 13:38
-
-
Save MarcelloDuarte/1229082 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Behat\Mink\Driver\Selenium; | |
use \PHPUnit_Extensions_SeleniumTestCase as SeleniumTestCase; | |
class Client extends SeleniumTestCase | |
{ | |
public function __construct($browser = '*firefox', $sid = null, | |
$host = 'http://localhost', | |
$port = 4444, $timeout = 30, $httpTimeout = 45) | |
{ | |
$this->browserName = $browser; | |
$this->data = array(); | |
$this->dataName = ''; | |
$this->testId = md5(uniqid(rand(), TRUE)); | |
$driver = new \PHPUnit_Extensions_SeleniumTestCase_Driver; | |
$driver->setBrowser($browser); | |
$driver->setHost($host); | |
$driver->setPort($port); | |
$driver->setTimeout($timeout); | |
$driver->setHttpTimeout($httpTimeout); | |
$driver->setTestCase($this); | |
$driver->setTestId($this->testId); | |
$this->drivers[] = $driver; | |
$this->setBrowser($browser); | |
$this->setBrowserUrl($host); | |
$this->setPort($port); | |
$this->start(); | |
} | |
// ... | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment