Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

implement node#selected?

  • Loading branch information...
commit 63e5a53c014ac2e35582f032c5fea7f01dd96583 1 parent 983b556
@halogenandtoast halogenandtoast authored
Showing with 8 additions and 0 deletions.
  1. +4 −0 lib/capybara/driver/webkit/node.rb
  2. +4 −0 src/capybara.js
View
4 lib/capybara/driver/webkit/node.rb
@@ -53,6 +53,10 @@ def visible?
invoke("visible") == "true"
end
+ def selected?
+ invoke("selected") == "true"
+ end
+
def checked?
self['checked']
end
View
4 src/capybara.js
@@ -91,6 +91,10 @@ Capybara = {
return true;
},
+ selected: function (index) {
+ return this.nodes[index].selected;
+ },
+
value: function(index) {
return this.nodes[index].value;
},
Please sign in to comment.
Something went wrong with that request. Please try again.