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

122
Vistas
Unable to click buttons with HtmlUnitDriver but able to click buttons with FirefoxDriver

I have a code using Selinium HtmlUnitDrive. I'm able to access the website and click the except cookies but I can't seem to click the play demo button. I don't what is a problem because I can click all buttons using FirefoxDriver.

Before I could not access any elements using HtmlUnitDriver until I used WebDriver driver = new HtmlUnitDriver(BrowserVersion.FIREFOX, true);

Can someone assist because I'm looking to use HtmlUnitDriver.

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

Possibly it's a typo as there are no blank spaces between Pl and ay. Effectively, you code block would be:

//CLICK DEMO BUTTON
wait.until(ExpectedConditions.elementToBeClickable(By.xpath("//button[text()='Play Demo ']"))).click();
System.out.println("DEMO BUTTON CLICKED");

Accomodating the blank space, you can use:

wait.until(ExpectedConditions.elementToBeClickable(By.xpath("//button[normalize-space()='Play Demo']"))).click();
about 4 years ago · Juan Pablo Isaza 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