Class: SiteEditor
- Inherits:
-
SiteSetupBase
- Object
- PageMaker
- BasePage
- SiteSetupBase
- SiteEditor
- Defined in:
- lib/sakai-cle-test-api/page_objects/site_setup.rb
Overview
The topmost “Site Editor” page, found in SITE MANAGEMENT or else Site Setup after you have selected to Edit a particular site.
Instance Method Summary collapse
- #return_button ⇒ Object
- #return_to_sites_list ⇒ Object
-
#set_role(participant, role) ⇒ Object
Sets the specified role for the specified participant.
- #update_participants ⇒ Object
Methods inherited from SiteSetupBase
Methods inherited from BasePage
basic_page_elements, frame_element
Methods inherited from PageMaker
element, expected_element, expected_title, #initialize, #method_missing, page_url
Constructor Details
This class inherits a constructor from PageMaker
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class PageMaker
Instance Method Details
#return_button ⇒ Object
127 128 129 |
# File 'lib/sakai-cle-test-api/page_objects/site_setup.rb', line 127 def frm.(:name=>"back") end |
#return_to_sites_list ⇒ Object
131 132 133 |
# File 'lib/sakai-cle-test-api/page_objects/site_setup.rb', line 131 def return_to_sites_list .click end |
#set_role(participant, role) ⇒ Object
Sets the specified role for the specified participant.
Because the participant is selected using a regular expression, the “participant” string can be anything that will suffice as a unique match–i.e., last name, first name, or user id, or any combination, as long as it will match a part of the string that appears in the desired row.
118 119 120 |
# File 'lib/sakai-cle-test-api/page_objects/site_setup.rb', line 118 def set_role(participant, role) frm.table(:class=>/listHier lines/).row(:text=>/#{Regexp.escape(participant)}/).select(:id=>/role/).select(role) end |
#update_participants ⇒ Object
122 123 124 125 |
# File 'lib/sakai-cle-test-api/page_objects/site_setup.rb', line 122 def update_participants frm.(:value=>"Update Participants").click SiteEditor.new(@browser) end |