Class: CitationListObject

Inherits:
Object
  • Object
show all
Includes:
PageHelper, Utilities, Workflows
Defined in:
lib/sakai-cle-test-api/data_objects/resource.rb

Instance Method Summary collapse

Methods included from Workflows

menu_link, #open_my_site_by_name

Methods included from Utilities

#current_hour, #current_month, #current_year, #get_filename, #in_15_minutes, #last_hour, #last_month, #last_year, #make, #make_date, #next_hour, #next_month, #next_year, #on_page, #random_alphanums, #random_alphanums_plus, #random_email, #random_high_ascii, #random_letters, #random_multiline, #random_nicelink, #random_string, #random_xss_string, #tomorrow, #yesterday

Methods included from PageHelper

#make, #on, #visit, #wait_until

Constructor Details

#initialize(browser, opts = {}) ⇒ CitationListObject

Returns a new instance of CitationListObject.



195
196
197
198
199
200
201
202
# File 'lib/sakai-cle-test-api/data_objects/resource.rb', line 195

def initialize(browser, opts={})
  @browser = browser

  defaults = {}
  options = defaults.merge(opts)
  @site = options[:site]
  raise "You must specify a Site for your Citations List" if @site==nil
end

Instance Method Details

#createObject



204
205
206
207
# File 'lib/sakai-cle-test-api/data_objects/resource.rb', line 204

def create
  open_my_site_by_name @site unless @browser.title=~/#{@site}/
  resources unless @browser.title=~/Resources$/
end