setValue() of input by ID with type='text' cuts off string.
See original GitHub issuesetValue of and input cuts off the entire string.
youtubeUrl = 'http://www.youtube.com/watch?v=YE7VzlLtp-4'
module.exports = {
'Uploading a Youtube Video' : function ( browser ) {
browser
.setValue( "#video_url", youtubeUrl )
}
};
Results in:
http://www.youtube.com/watch?v=YE7Vzl
Cutting off the rest of the string.
As well as a vimeo movie:
https://vimeo.com/1084537
Results in:
https://vimeo.com/1
Although this seems to work:
youtubeUrl = 'https://www.youtube.com/123456789012345678910'
Any ideas if this is a bug or am I doing something incorrect?
Issue Analytics
- State:
- Created 7 years ago
- Comments:18 (3 by maintainers)
Top Results From Across the Web
Losing text after a space setting the value in a new field
I give those text fields a string as a value. However, it is only working correctly if I give it a string with...
Read more ><input type="text"> - HTML: HyperText Markup Language | MDN
Value. The value attribute is a string that contains the current value of the text entered into the text field. You can retrieve...
Read more >HTML DOM Input Text value Property - W3Schools
The value property sets or returns the value of the value attribute of a text field. The value property contains the default value...
Read more >Google Visualization API Reference | Charts
The output of this method can be used as input to DataView.setRows() to change the displayed set of rows in a visualization.
Read more >Set the value of an input field in JavaScript - GeeksforGeeks
JavaScript setAttribute() Method: This method adds the specified attribute to an element and sets its specified value.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

So I ended up writing an extension command to nightwatch:
setValueSlow.js
index.d.ts (typings extension since I’m using TypeScript):
Usage:
I am using chromedriver version 2.35 and is happening with some inputs too. Any solution working right now?