No se puede conectar al host 127.0.0.1 en el puerto 7055
Soy un novato con webdriver y necesito ayuda ..
Estoy usando Selenium 2.2.0 con FF v7.0.1 en Windows XP
Logré grabar y reproducir una secuencia de comandos java con éxito en IE pero cada vez que intento ejecutar la misma secuencia de comandos en FF, aparece el siguiente mensaje de error:
No se puede conectar al host 127.0.0.1 en el puerto 7055 después de 45000 ms
He leído en muchos lugares que si cambié la versión de Firefox a la versión 3.6 el script funcionará bien, pero no estoy interesado en la degradación. ¿Alguien por favor me puede decir qué estoy haciendo mal?
<code>package hisScripts; import java.util.concurrent.TimeUnit; import org.junit.*; import static org.junit.Assert.*; import org.openqa.selenium.*; import org.openqa.selenium.firefox.FirefoxDriver; public class WebdriverTest_1 { private WebDriver driver; private String baseUrl; private StringBuffer verificationErrors = new StringBuffer(); @Before public void setUp() throws Exception { driver = new FirefoxDriver(); //driver=new InternetExplorerDriver(); baseUrl = "https://**********/"; driver.manage().timeouts().implicitlyWait(30, TimeUnit.SECONDS); } @Test public void testUntitled() throws Exception { driver.get(baseUrl + "/"); driver.findElement(By.xpath("//a[contains(text(),'my profile')]")).click(); driver.findElement(By.xpath("//a[contains(text(),'about the service')]")).click(); driver.findElement(By.xpath("//a[contains(text(),'contact us')]")).click(); driver.findElement(By.xpath("//a[contains(text(),'help')]")).click(); driver.findElement(By.xpath("//a[contains(text(),'home')]")).click(); driver.findElement(By.xpath("//a[contains(text(),'logout')]")).click(); } @After public void tearDown() throws Exception { driver.quit(); String verificationErrorString = verificationErrors.toString(); if (!"".equals(verificationErrorString)) { fail(verificationErrorString); } } private boolean isElementPresent(By by) { try { driver.findElement(by); return true; } catch (NoSuchElementException e) { return false; } } </code>
}