java.lang.NoSuchMethodError: org.openqa.selenium.os.CommandLine.find (Ljava / lang / String;) Ljava / lang / String; enquanto estiver usando o PhantomJS 2.1.1 com Selenium
SO - Windows 7
PhantomJS versão - 2.1.1
Selenium - 3.8.1 (servidor de selênio).
JDK - 152.
Estou tentando executar um teste simples, usando o PhantomJS:
1) inicializando o driver:
System.setProperty("phantomjs.binary.path","src\\main\\resources\\phantomjs.exe");
WebDriver driver = new PhantomJSDriver();
2) qualquer teste, verifique o texto "bem-vindo" em en.wikipedia.org:
driver.get("http://en.wikipedia.org");
System.out.println(driver.findElement(By.xpath("//div[contains(text(),'Welcome')]")).isDisplayed());
3) Teste de execução, mas recebendo erros:
Exception in thread "main" java.lang.NoSuchMethodError: org.openqa.selenium.os.CommandLine.find(Ljava/lang/String;)Ljava/lang/String;
at org.openqa.selenium.phantomjs.PhantomJSDriverService.findPhantomJS(PhantomJSDriverService.java:232)
at org.openqa.selenium.phantomjs.PhantomJSDriverService.createDefaultService(PhantomJSDriverService.java:181)
at org.openqa.selenium.phantomjs.PhantomJSDriver.<init>(PhantomJSDriver.java:104)
at org.openqa.selenium.phantomjs.PhantomJSDriver.<init>(PhantomJSDriver.java:94)
O Google mostrou que esses problemas ocorrem de tempos em tempos (selênio não compatível / PhantomJS). Pergunta: existe alguma solução alternativa para fazer o último selênio (s) e 2.1.1 PhantomJS bons amigos?
nota: qualquer outro driver funciona bem (borda, cromo, ff).