You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 29, 2018. It is now read-only.
What steps will reproduce the problem?
1. Using Protractor with Selenium testing Firefox 31 with Sauce Labs configured for
Linux, use code like the following in a test of an input element with type "number":
element(by.id('id_count')).sendKeys('100');
expect(element(by.id('id_count')).getAttribute('value')).toBe('100');
What is the expected output? What do you see instead?
The expected behavior is for a value of '100' to be retrieved. Instead, the retrieved
value is the empty string.
Selenium version: 2.42.1
OS: Linux
Browser: Firefox
Browser version: 31
Please provide any additional information below. A sample reduced test
case, or a public URL that demonstrates the problem will intrigue our merry
band of Open Source developers far more than nothing at all: they'll be far
more likely to look at your problem if you make it easy for them!
Things work as expected with Firefox 28. See also this Stackoverflow post which contains
more info and a simpler way to reproduce the issue:
http://stackoverflow.com/questions/23412912/selenium-send-keys-doesnt-work-if-input-type-number
Reported by chris.jerdonek on 2014-08-30 18:00:42
The text was updated successfully, but these errors were encountered:
Please provide a proof of the issue. I can't reproduce it.
Here is the sample code:
DesiredCapabilities capabilities = DesiredCapabilities.firefox();
capabilities.setVersion("31");
capabilities.setPlatform(Platform.LINUX);
capabilities.setCapability("selenium-version", "2.42.1");
// Create the connection to Sauce Labs to run the tests
WebDriver driver = new RemoteWebDriver(
new URL("http://xxx:xxx@ondemand.saucelabs.com:80/wd/hub"),
capabilities);
driver.get("http://fiddle.jshell.net/barancev/4xmnde8s/show/light/");
WebElement num = driver.findElement(By.id("num"));
num.sendKeys("100");
System.out.println(num.getAttribute("value"));
driver.quit();
And the result is: https://saucelabs.com/tests/3d3174055f734a70811f9791230bd987
Thanks for looking into this. Hmm, here is an example of one of my Travis failures:
https://travis-ci.org/cjerdonek/quick-sampler/builds/33986945
And here is the line of test code:
https://github.com/cjerdonek/quick-sampler/blob/1ce18051180b0b2515bd891e3eac11fbd00a62a8/test/e2e/test.js#L47
This simple assertion passed on Sauce Labs with Chrome and IE 10, but never with Firefox
31. It started passing only when I switched to Firefox 28 and kept everything else
the same.
How is your test different from what is described in the Stackoverflow post? My experience
matches what was described there. Do you have a suggestion for what else I should
try? If I can only reproduce the issue using Protractor, should I file a Protractor
issue?
@barancev, could you try running your test against the following URL with input element
id "id_total_count"?
http://cjerdonek.github.io/quick-sampler/#/
Okay, you can close this.
I figured out what was wrong. I wasn't telling Sauce Labs what Selenium version to
use, and Sauce Labs defaults to an old version. Manually specifying the latest version
gets things working. Thanks.
Originally reported on Google Code with ID 7809
Reported by
chris.jerdonek
on 2014-08-30 18:00:42The text was updated successfully, but these errors were encountered: