Avatar of Ruwenzori Warrior
Ruwenzori Warrior
 asked on

Use Selenium CLI to execute a text on Selenium Grid

I have a selenium docker grid on my local machine. I used Selenium IDE to create a .side file, by recording a test. I am using selenium-side-runner, the Selenium CLI to execute the .side test on the Selenium Grid.


When I execute the test on the Grid, I get :

WebDriverError: unknown error: net::ERR_CONNECTION_REFUSED

SeleniumDocker

Avatar of undefined
Last Comment
Ruwenzori Warrior

8/22/2022 - Mon
Kimputer

 What was the command, to connect to what server? That server currently doesn't accept your request.
Ruwenzori Warrior

ASKER
This was the command:

selenium-side-runner StaffPortalLogin.side --server http://localhost:4444/wd/hub -c "browserName='chrome', goog:chromeOptions.args=[no-sandbox,start-maximized,headless,window-size=1366x768,disable-popup-blocking,disable-dev-shm-usage,dns-prefetch-disable,always-authorize-plugins,disable-gpu,enable-automation,disable-browser-side-navigation,ignore-certificate-errors,disable-extensions,use-gl=egl,single-process,ignore-certificate-errors,allow-running-insecure-content] platform='LINUX'"

Open in new window


The server (hub) is a docker container, running on my local machine on port 4444.

Kimputer

So you're sure on that same machine, a normal browser, would get a page when going to http://localhost:4444/wd/hub ?
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck
Ruwenzori Warrior

ASKER
This is what I am getting when hitting that page:

Ruwenzori Warrior

ASKER
And this is what I get, when I hit localhost:4444


Ruwenzori Warrior

ASKER
This is the console:



Get an unlimited membership to EE for less than $4 a week.
Unlimited question asking, solutions, articles and more.
Kimputer

As you can see from your first browser screenshot, it ends with an error. So when you use that page to test, the error will also show up. Fix the error on the page, and you'll fix the error with your CLI command.
Ruwenzori Warrior

ASKER
Did a google search for the error popping up on the hub URL when loaded in browser, came across this:

https://github.com/zalando/zalenium/issues/305
ASKER CERTIFIED SOLUTION
Ruwenzori Warrior

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question