I was just about to try Test::WWW::Selenium with Alien::SeleniumRC as suggested by Barbie here but I can't even get the example in the synopsis to work.
use Test::More tests => 1; use Test::WWW::Selenium; # Parameters are passed through to WWW::Selenium my $sel = Test::WWW::Selenium->new( host => "localhost", port => 4444, browser => "*firefox", browser_url => "http://www.google. +com", default_names => 1, ); # use special test wrappers around WWW::Selenium commands: $sel->open_ok("http://www.google.com");

When I run the test script it is stuck and in the browser (Firefox) I can see it was trying to access

http://www.google.com/selenium-server/core/RemoteRunner.html?sessionId +=718835&multiWindow=false&baseUrl=http%3A%2F%2Fwww.google.com&debugMo +de=false
and got 404.

So what am I doing wrong?

Update

OS: Ubuntu 7.10
Browser Firefox
Actual string in configuration is
browser => "*custom /usr/bin/firefox",

No proxy in my network that I am aware of, but there might be transparent proxies...
perl 5.8.8
Test::WWW::Selenium is up to date (1.14).
Alien::SeleniumRC is up to date (0.91).

Solution

The browser configuration need to be changed to:
browser => "*chrome /usr/lib/firefox/firefox-bin",

In reply to Selenium example not working? by szabgab

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.