Method: PageObject::SectionCollection#select_by
- Defined in:
- lib/page-object/section_collection.rb
#select_by(values_hash) ⇒ Object
9 10 11 12 13 14 |
# File 'lib/page-object/section_collection.rb', line 9 def select_by(values_hash) matches = select do |section| values_hash.all? { |key, value| value === section.public_send(key) } end self.class[*matches] end |