Selenium, opening ff browser and automaticly close - selenium

Trying to run testng suite compiled jar on remote linux machine.
Problem I have is, if I run tests, FF open url I have defined and after that closing brower, and so on.
org.openqa.selenium.NoSuchElementException: Unable to locate element: {"method":"name","selector":"username"}
Selenium 2.53.0
FF 45.0
Any idea why my test just open browser and close?

NoSuchElementException is thrown when element does not exist. It may not be the reason for fx crash.
The possibilities are :
Some where in the code you will be closing the driver.
I had faced the same issue earlier.
Try to upgrade your firefox to the latest version.
Try to set the firefox driver using setProperties
System.setProperty("webdriver.firefox.bin","C:\\Users\\AppData\\Local\\Mozilla Firefox\\firefox.exe");
WebDriver driver=new FirefoxDriver();
Follow the link to upgrade or downgrade fx: https://support.mozilla.org/t5/Install-and-Update/Install-an-older-version-of-Firefox/ta-p/1564
Below are some of the helpful links.
Firefox crashes when started by Selenium firefox driver
Which Firefox version is compatible with Selenium 2.53.0?

I was using wrong url without "/" on the end, after I changed all working now.

Related

Jmeter WebDriver don't start

I tried to run WebDriver Sampler, but got problem with driver config.
First I tried to use Firefox Driver Config. When run only Firefox Driver Config (without any sampler) I see how Firefox launched but finally got error:
org.openqa.selenium.WebDriverException: Failed to connect to binary FirefoxBinary(C:\Program Files (x86)\Mozilla Firefox\firefox.exe) on port 7055; process output follows: ddons.json found.
Next I tried to use Chrome Driver config, but got error:
The driver executable does not exist.
I tried to solve the problem like this: How to solve this error an jmetere, but it doesn’t work.
Image with config and errors
With regards to Firefox you need to ensure that you use supported Firefox version. The latest JMeter WebDriver Plugin kg.apc:jmeter-plugins-webdriver:2.3 has transitive dependency on the selenium-firefox-driver:2.52.0 which means that you can use Firefox 45 or earlier with it.
Later Firefox versions will not work.
You can download Firefox 45 from Mozilla FTP website
More information: Q. How do I Know Which Browsers are Supported? chapter of The WebDriver Sampler: Your Top 10 Questions Answered guide
I found the tab with configuration path to driver
Picture with tab:

Unable to run WebDriverIo tutorial

I'm trying to follow the WebDriverIo tutorial at http://webdriver.io/guide.html .
After setting up the Selenium server, when I try executing the test node script (step 7 in the tutorial), selenium warns me of some errors (see screenshot for full log), and I don't get any output returned.
Steps to reproduce:
I start the Selenium server
When I try running the node script, this happens (clock to zoom):
At this point a Firefox window opens automatically, and remains blank.
I'm running Firefox v52 and Selenium 3.0.1. I downloaded Geckodriver from https://github.com/mozilla/geckodriver/releases
Any obvious thing that I'm missing? I'm very new to Selenium and browser automation, forgive the generic input :)
If you have been here to get your Windows release of gecko driver : https://github.com/mozilla/geckodriver/releases, you may have miss this message :
"IMPORTANT: If you use geckodriver with Selenium, you must upgrade to
Selenium 3.3 since this release aligns HTTP responses with the
WebDriver standard."
(I can see you are in v3.0.1).

driver.switchTo().alert().sendKeys("Hello") not working for latest chrome driver- Selenium Webdriver -java

driver.switchTo().alert().sendKeys("Hello")
The above code for prompt is not working for latest chrome driver with selenium webdriver -java. It didn't throw any error. Except sendkeys all other actions accept(),dismiss() , getText() is working well. I have used ChromeDriver 2.29, selenium-3.3.1, Chrome Browser - Version 56.0.2924.87.
google chrome
Version 59.0.3071.109
chrome driver 2.30
selenium 3.4
i have this version for chrome.
driver.switchTo().alert().sendKeys("Helllo")
is working properly.
This is purely a display issue and the input of sendKeys(...) will be sent after you accept the Alert.
See also the answer in this Chromium issue:
https://bugs.chromium.org/p/chromedriver/issues/detail?id=1120#c11

It downloading only Selenium WebDriver 3.0.0-beta2.. 2.53.1 In selenium Web Driver i cant able to Download

Old Version WebDriver I can't able to download At present I am using 46.0 Version in Firefox and WebDriver 2.53.0 in Windows 7. It working Fine. But if I update my browser. I cant able to run the test case, it showing browser error.
I update my Browser 47.0 & 48.0beta and used Selenium WebDriver 3.0.0-beta2 that also showing error. now, the version I cant able to download. I am just struck in this. Any solution there for this??

Which Firefox version is compatible with Selenium 2.53.0?

Which Firefox version is compatible with Selenium 2.53.0? I tried Firefox 45.0 and I am getting this exception:
org.openqa.selenium.WebDriverException: Failed to connect to binary
FirefoxBinary(/Applications/Firefox.app/Contents/MacOS/firefox-bin) on port 7055; process output follows:
foreignInstall":false,"hasBinaryComponents":false,"strictCompatibility":false,"l ocales":[],"targetApplications":[{"id":"{ec8030f7-c20a-464f-9b0e-13a3a9e97384}","minVersion":"45.0","maxVersion":"45.*"},{"id":"xpcshell#tests.mozilla.org","minVersion":"0","maxVersion":"10"}],"targetPlatforms":[],"multiprocessCompatible":false,"seen":true}
I had the similar problem running Selenium Webdriver 2.53.0 with Firefox 47.0.
Selenium Webdriver 2.53.0 works with Firefox 46.0. You can find the the mentioned version at https://support.mozilla.org/en-US/kb/install-older-version-of-firefox.
Also you could try to add:
System.setProperty("webdriver.firefox.bin","C:\\Users\\AppData\\Local\\Mozilla Firefox\\firefox.exe");
WebDriver driver=new FirefoxDriver();
if it is also not working, then you need to downgrade your FF
hi I had the same problem, I hope you have solved yours, but maybe my answer can help someone else.
i found firefox 26, selenium 2.48.2 and a webdriver that work very good together. here are the download links:
phpSeleniumWebDrive
selenium-server-standalone-2.48.2
firefox26