Class: ManageDiscussions

Inherits:
BasePage show all
Includes:
JForumsResources
Defined in:
lib/sakai-cle-test-api/page_objects/jforums.rb

Overview

The Manage Discussions page in Discussion Forums.

Instance Method Summary collapse

Methods included from JForumsResources

#discussion_home, #manage, #member_listing, #my_bookmarks, #my_profile, #private_messages, #search

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

#forum_titlesObject

Creates and returns an array of forum titles which can be used for verification



158
159
160
161
162
163
# File 'lib/sakai-cle-test-api/page_objects/jforums.rb', line 158

def forum_titles
  forum_titles = []
  forum_links = frm.links.find_all { |link| link.id=="forumEdit"}
  forum_links.each { |link| forum_titles << link.text }
  return forum_titles
end

#manage_forumsObject

Clicks the Manage Forums link, then instantiates the ManageForums Class.



151
152
153
154
# File 'lib/sakai-cle-test-api/page_objects/jforums.rb', line 151

def manage_forums
  frm.link(:text=>"Manage Forums").click
  ManageForums.new(@browser)
end