Skip to content

Instantly share code, notes, and snippets.

@Su-Shee
Created July 8, 2014 15:23
Show Gist options
  • Save Su-Shee/5b0b003617357c50fb41 to your computer and use it in GitHub Desktop.
Save Su-Shee/5b0b003617357c50fb41 to your computer and use it in GitHub Desktop.
#!/usr/bin/env perl
use strict;
use warnings;
use feature 'say';
use Selenium::Remote::Driver;
my $driver = Selenium::Remote::Driver->new();
$driver->get('http://localhost:63696/');
say $driver->get_current_url();
my $login_url = $driver->find_element("//a[contains(text(), 'Anmelden')]");
$login_url->click();
my $login = $driver->find_element('//input[@name="email"]');
$login->send_keys('FOO FOO FOO');
my $password = $driver->find_element('//input[@name="password"]');
$password->send_keys('BAR BAR BAR');
my $submit = $driver->find_element('//input[@value="Anmelden"]');
$submit->click();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment