hbarnard has asked for the wisdom of the Perl Monks concerning the following question:

I have a fairly substantial, but 'old', set of tests for Cclite. They use, or used use Test::WWW::Selenium; which now doesn't seem to find a webdriver on any version of Selenium that I download

Error requesting http://10.0.0.65:4444/selenium-server/driver/: 404 Not Found

My tests all take the form of

$sel->open_ok("/cgi-bin/cclite.cgi"); $sel->type_ok("registry", 'dalston'); $sel->type_ok("userLogin", $user); $sel->type_ok("userPassword", "password"); $sel->submit("form") ;

I'd really like to find some way to use/re-use them without too much extra work. I'm prepared to do a little Java and recompile Selenium if it comes to that

Replies are listed 'Best First'.
Re: Update Old Selenium Tests
by marto (Cardinal) on Nov 12, 2025 at 13:27 UTC
Re: Update Old Selenium Tests
by LanX (Saint) on Nov 12, 2025 at 14:55 UTC
    > without too much extra work.

    Marto's suggestion to migrate to Test::Selenium::Remote::Driver could be elegantly done by writing your own module Test::WWW::Selenium::Bridge that copies the API of the old module and maps the calls to wrap the new one.

    Like this you'd only have to append ::Bridge to all your uses of Test::WWW::Selenium in your "fairly substantial, but 'old', set of tests"

    This should be not too hard if you are really ...

    > My tests all take the form of

    ... only using 3 methods + new.

    Disclaimer: I never used Selenium. Here might meet be dragons or other road bumps.

    But even if it's more complicated, this strategy should give you quick results and reduce your migration risks.

    Cheers Rolf
    (addicted to the Perl Programming Language :)
    see Wikisyntax for the Monastery

Re: Update Old Selenium Tests
by hbarnard (Initiate) on Nov 13, 2025 at 08:58 UTC
    Thanks for your replies. I can see that there's work ahead one way or another. As such I think I'll do a little experiment with https://metacpan.org/pod/WWW::Mechanize and knock Selenium out of the picture altogether. My new incarnation is Mojolicious based, so there's good inbuilt testing already within the infrastructure.