Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

261
Vistas
How to run webdriver tests on docker firefox-standalone-debug container instead of regular firefox browser

I have a regular Firefox installed on my Linux Ubuntu as well as docker-firefox-standalone-debug container. Moreover I have Xfvb and I set DISPLAY overthere. Now when I run my Webdriver test from Jenkins everything works fine and my test runs on regular Firefox. But the problem is that I would like to start my test now on docker-firefox-standalone-debug container. Can anyone tell me how to force my test on Jenkins to run on docker? By default it starts on regular Firefox and I don't now how to tell him yo run on docker-firefox-debug?

about 4 years ago · Santiago Trujillo
2 Respuestas
Responde la pregunta

0

You'll need to use the remote web driver instead of the regular WebDriver.

For example if you run your conatiner as follows:

docker run -d -p 4444:4444 selenium/standalone-firefox-debug

Use the follwing code:

RemoteWebDriver driver = new RemoteWebDriver(
                    new URL("http://localhost:4444/wd/hub"),
                    DesiredCapabilities.firefox());

Instead of:

WebDriver driver = new FirefoxDriver();

Regards

about 4 years ago · Santiago Trujillo Denunciar

0

I run:

docker run -d -p 32780:4444 -p 5999:5900 selenium/standalone-firefox-debug

so when I type

docker ps

I have

6b7fa91575ae selenium/standalone-firefox-debug "/opt/bin/entry_point" 8 seconds ago Up 6 seconds 0.0.0.0:32780->4444/tcp, 0.0.0.0:5999->5900/tcp

then in my code:

RemoteWebDriver driver = new RemoteWebDriver( 
                                new URL("http://192.168.99.100:32780/wd/hub"), 
                                DesiredCapabilities.firefox());

This works :)

about 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda