Skip to content

Instantly share code, notes, and snippets.

@testingbot
Created May 20, 2014 14:23
Show Gist options
  • Save testingbot/dd879dcbc004db99b780 to your computer and use it in GitHub Desktop.
Save testingbot/dd879dcbc004db99b780 to your computer and use it in GitHub Desktop.
testingbot perl
use Selenium::Remote::Driver;
#Input capabilities
my $extraCaps = {
"browser" => "internet explorer",
"version" => "7",
"platform" => "Windows"
};
my $key = "changeme";
my $secret = "changeme";
my $host = "$key:$secret\@hub.testingbot.com";
my $driver = new Selenium::Remote::Driver('remote_server_addr' => $host,
'port' => '80', 'extra_capabilities' => $extraCaps);
$driver->get('http://www.google.com');
$driver->find_element('q','name')->send_keys("TestingBot");
print $driver->get_title();
$driver->quit();
@testingbot
Copy link
Author

Selenium Installation from command line:

cpanm Selenium::Remote::Driver

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment