Owner: ----
Labels: Type-Defect Priority-Medium Status-Untriaged
New issue 8240 by 3...@detfalskested.dk: Make calling WebElement
manipulation methods chainable
https://code.google.com/p/selenium/issues/detail?id=8240
This is a feature request.
An example: If I want to change the text of an input field, i first have to
clear it, then enter the new text. For this, I either need to assign the
element to a variable to call .clear() and .send_keys() on it, or find the
element twice.
click, submit, clear, send_keys (possibly others?) have no return values.
I'd like them to return self, to allow me to optimise my example from
something like:
my_element.clear()
my_element.send_keys('new text')
To:
my_element.clear().send_keys('new_text')
Are there good arguments against this behaviour?
If not, I could even implement this myself (and push the code back to you),
but only for some of the supported languages, as I don't feel confident
with all of them.
--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings
--
You received this message because you are subscribed to the Google Groups "Selenium Developer Activity" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-developer-activity+unsubscribe@googlegroups.com.
To post to this group, send email to selenium-developer-activity@googlegroups.com.
Visit this group at http://groups.google.com/group/selenium-developer-activity.
For more options, visit https://groups.google.com/d/optout.