I'm experiencing a problem running Selenide tests in Firefox version 46. When tests run separately everything works fine. But when I run all test methods in class it hangs on the following step:
addons.productaddons INFO sending request to: https://aus5.mozilla.org/update/3/GMP/46.0/20160421124000/WINNT_x86_64-msvc-x64/en-US/release/Windows_NT%206.1.1.0%20(x64)/default/default/update.xml
addons.productaddons INFO Completed downloading document
addons.productaddons INFO Downloading from https://cdmdownload.adobe.com/firefox/win/x64/primetime_gmp_win_x64_gmc_40673.zip to C:\Users\hunar_letsko\AppData\Local\Temp\tmpaddon
addons.productaddons INFO Downloading from http://ciscobinary.openh264.org/openh264-win64-0410d336bb748149a4f560eb6108090f078254b1.zip to C:\Users\hunar_letsko\AppData\Local\Temp\tmpaddon
addons.manager INFO Skipping background update check
DeferredSave.extensions.json DEBUG Save changes
DeferredSave.extensions.json DEBUG Starting timer
DeferredSave.extensions.json DEBUG Starting write
DeferredSave.extensions.json DEBUG Write succeeded
One more note: when test method are running more than 3 hours of hanging it fails with connection timeout:
org.openqa.selenium.WebDriverException: java.net.SocketTimeoutException: Read timed out
Build info: version: '3.0.0', revision: '350cf60', time: '2016-10-13 10:48:57 -0700'
System info: host: 'EPBYMINW2815', ip: '10.6.9.56', os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '1.8.0_92'
Driver info: driver.version: RemoteWebDriver
selenide.url: app_url"
selenide.baseUrl: http://localhost:8080
at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(DriverCommandExecutor.java:91)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:601)
at org.openqa.selenium.remote.RemoteWebDriver.get(RemoteWebDriver.java:322)
at org.openqa.selenium.remote.RemoteWebDriver$RemoteNavigation.to(RemoteWebDriver.java:902)
at com.codeborne.selenide.impl.Navigator.navigateToAbsoluteUrl(Navigator.java:69)
at com.codeborne.selenide.impl.Navigator.open(Navigator.java:31)
at com.codeborne.selenide.Selenide.open(Selenide.java:81)
at com.codeborne.selenide.Selenide.open(Selenide.java:55)
at
where app_url is my application's url.
Thanks for any help in advance, guys!
You need to downgrade Selenide. Selenide 4.0 works bad with Firefox.
Related
I am getting an weird error for a specific URL. I am running selenium webdriver script using TestNG, eclipse, and Maven.
My test:
#TestNG
{
MyPage mypg = new MyPage(driver);
mypage.openURL();
}
Calls this method:
public void openURL(){
//driver.get("http://www.site1.com/");
//driver.get("http://www.site2.com/");
driver.get("http://www.site3.com/");
System.out.println("Opened the URL");
}
When I run my test, site1 and site2 works just fine. It opens the URLS and then prints the message.
However, when I run my test for site3, it opens site3.com and then status stays in running mode. It never prints the message "opened the URL" and running mode(red button) stays on. Then I see the below error. I am not sure why it is acting this way for site3. It works for site1 and site2. I updated the maven project. I restarted Eclipse. It did not help. Please advise.
org.openqa.selenium.WebDriverException: unknown error: cannot
determine loading status from unknown error: missing or invalid
'entry.level' (Session info: chrome=63.0.3239.132) (Driver info:
chromedriver=2.29.461591
(62ebf098776g1772160f391d75e589dc567915b233),platform=Windows NT
140.10.155063 x86_64) (WARNING: The server did not provide any stacktrace information) Command duration or timeout: 1.29 seconds
Build info: version: '3.4.0', revision: 'unknown', time: 'unknown'
System info: host: 'L-XP79550-A8198', ip: '1x2.1xx.1.1xx', os.name:
'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version:
'1.8.0_131' Driver info: org.openqa.selenium.chrome.ChromeDriver
I have a testng test. When I run the script, it opens URL and print message just fine. It d
After adding the dependencies to pom.xml, site3.com worked. Still not sure why site1 and 2 worked without these dependencies but site3 did not work. At least now it worked.
maven-compiler-plugin
maven-surefire-plugin
webdrivermanager
selenium-chrome-driver
When I start the selenium test with gird (Remote control), I see this ERROR on log. The browser is not able to open. I did check and tried the following things:
Stop and start both hub and node. I use the default commands to start hub and node. From command prompt, I see that the node was registered successfully and ready to use
Clean Eclipse Project at Project>Clean
Restart my PC
Disconnect VPN
Use latest selenium standalone 3.6; chromedriver.exe
Check the path to chromedriver.exe
Use my PC as hub and another PC as node
Please note that this issue only happen if I run the test with grid (remote control). The test can run normally locally.
2017-10-20 15:23:37,805 ERROR [Log] Class Utils | Method OpenBrowser | Exception desc : Unable to create new service: ChromeDriverService
Build info: version: '3.6.0', revision: '6fbf3ec767', time: '2017-09-27T16:15:40.131Z'
System info: host: 'MY-PC', ip: 'xx.xxx.xxx.xx', os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '1.8.0_121'
Driver info: driver.version: unknown
Command duration or timeout: 319 milliseconds
Please give me advice in this case. Thanks!
I have some Java scripts for Chrome browser and now I want to run the scripts in htmlUnit. I think the scripts are the same for both, but I got some error when running in htmlUnit? why? So basically which actions (click()? isDisplayed()? etc.) only in Browser test but not in headless tests? and general documents about this difference? Thanks
######### Seems css may have problem here but work OK in Chrome ##############
Exception in thread "main" org.openqa.selenium.NoSuchElementException:
Returned node was not an HTML element For documentation on this error,
please visit: http://seleniumhq.org/exceptions/no_such_element.html
Build info: version: '2.45.0', revision: '32a636c', time: '2015-03-05
22:01:35' System info: host: 'FGS-CIT-2758', ip: '192.168.200.201',
os.name: 'Windows 7', os.arch: 'x86', os.version: '6.1', java.version:
'1.8.0_40' Driver info: driver.version: HtmlUnitDriver at
org.openqa.selenium.htmlunit.HtmlUnitDriver.findElementByCssSelector(HtmlUnitDriver.java:1002)
at org.openqa.selenium.By$ByCssSelector.findElement(By.java:426) at
org.openqa.selenium.htmlunit.HtmlUnitDriver$5.call(HtmlUnitDriver.java:1648)
at
org.openqa.selenium.htmlunit.HtmlUnitDriver$5.call(HtmlUnitDriver.java:1)
at
org.openqa.selenium.htmlunit.HtmlUnitDriver.implicitlyWaitFor(HtmlUnitDriver.java:1302)
at
org.openqa.selenium.htmlunit.HtmlUnitDriver.findElement(HtmlUnitDriver.java:1644)
at
org.openqa.selenium.htmlunit.HtmlUnitDriver.findElement(HtmlUnitDriver.java:550)
at com.ATIP400Suite.CH_ATIP40.mainCheck(CH_ATIP40.java:461) at
com.ATIP400Suite.CH_ATIP40.main(CH_ATIP40.java:58)
Line461 =
driver.findElement(By.cssSelector("span.icon-meter.enlargeIcon")).isDisplayed()
Did you enable javascript in HtmlUnitDriver?
If yes, before click check ExpectedConditions:
presenceOfElementLocated (if you are not sure that an element is present on the DOM)
elementToBeClickable
good luck...
I try to run a selenium client that interacts with remote selenium web driver server.
Some (only some) of my tests are failing because of connection refused.
What should I check on the machine that hosts the server?
com.x.inject.ProvisionException: Guice provision errors:
1) Error in custom provider, org.openqa.selenium.remote.UnreachableBrowserException: Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure.
Build info: version: '2.44.0', revision: '76d78cf323ce037c5f92db6c1bba601c2ac43ad8', time: '2014-10-23 13:11:40'
System info: host: 'w04.hfa.corp.x.com', ip: '172.28.144.7', os.name: 'Linux', os.arch: 'amd64', os.version: '3.13.0-30-generic', java.version: '1.8.0_25'
Driver info: driver.version: RemoteWebDriver
while locating com.waze.testing.guice.providers.WebDriverProvider
at com.waze.testing.MainModule.configure(MainModule.java:44)
while locating org.openqa.selenium.WebDriver
1 error
at com.x.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1009)
at com.x.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1035)
at com.waze.testing.cucumber.steps.Hooks.before(Hooks.java:39)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
Selenium 2.44 and "Native Method" phrase in the traceback makes me think this is a compatibility problem. Upgrade selenium to the latest (2.46 currently) version.
I am using chrome browser in selenium project.
Here is the user agent string that I am using:
System.setProperty("webdriver.chrome.driver","C:\\users\\..\\chromedriver.exe");
driver = new ChromeDriver();
What happens IF I run the script:
It open the chrome browser and after some time it close it and giving error:
org.openqa.selenium.WebDriverException: unknown error: unable to
discover open pages (Driver info: chromedriver=2.2,platform=Windows
NT 6.1 x86) (WARNING: The server did not provide any stacktrace
information) Command duration or timeout: 26.83 seconds Build info:
version: '2.39.0', revision: 'ff23eac', time: '2013-12-16 16:12:12'
System info: host: 'QAVM-9', ip: '27.101.1.26', os.name: 'Windows 7',
os.arch: 'x86', os.version: '6.1', java.version: '1.7.0_45' Driver
info: org.openqa.selenium.chrome.ChromeDriver at
sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
at
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
at
org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:193)
at
org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:145)
at
org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:554)
at
org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:216)
at
org.openqa.selenium.chrome.ChromeDriver.startSession(ChromeDriver.java:182)
at
org.openqa.selenium.remote.RemoteWebDriver.(RemoteWebDriver.java:111)
at
org.openqa.selenium.remote.RemoteWebDriver.(RemoteWebDriver.java:115)
at
org.openqa.selenium.chrome.ChromeDriver.(ChromeDriver.java:161)
at
org.openqa.selenium.chrome.ChromeDriver.(ChromeDriver.java:150)
at
org.openqa.selenium.chrome.ChromeDriver.(ChromeDriver.java:139)
Please help me, It completely stop the execution.
Let me know in case need any other information.
I would suggest you to update your chrome driver since your version is 2.2 and the latest is 2.9. It might be possible that your existing chrome driver might not be supporting your chrome browser if the browser is of latest version.
Chrome driver versions are here
Also check the release notes here. Each chromedriver mentions which chrome browser versions
it supports.
Here's what I did to get rid of that error (
unknown error: unable to discover open pages
)
In your protractor config file, add the following:
capabilities: {
browserName: 'chrome',
chromeOptions: {
args: ['--no-sandbox']
}
},
The most important line there is the --no-sandbox; adding that line somehow gets rid of that error.
I am not exactly sure why it works but it's a workaround I found while digging around online.