Skip to content

Commit

Permalink
Shrinkwrapped support for TestingBot
Browse files Browse the repository at this point in the history
  • Loading branch information
chibimagic committed Mar 4, 2015
1 parent 842fb0e commit 50d8a40
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions WebDriver/Driver.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,17 @@ public static function InitAtBrowserStack($browserstack_username, $browserstack_
}
return new WebDriver_Driver("http://" . $browserstack_username . ":" . $browserstack_value . "@hub.browserstack.com/wd/hub", $capabilities);
}

public static function InitAtTestingBot($testingbot_apikey, $testbot_secret, $os, $browser, $version = false, $additional_options = array()) {
$capabilities = array_merge(array(
'platform' => strtoupper($os),
'browserName' => $browser
), $additional_options);
if ($version) {
$capabilities["version"] = $version;
}
return new WebDriver_Driver("http://" . $testingbot_apikey . ":" . $testbot_secret . "@hub.testingbot.com:4444/wd/hub", $capabilities);
}

public static function InitAtHost($host, $port, $browser, $additional_options = array()) {
$capabilities = array_merge(array(
Expand Down

0 comments on commit 50d8a40

Please sign in to comment.