Module: Profile2ConnectionsMethods

Includes:
PageObject
Defined in:
lib/kuali-sakai-common-lib/profile2.rb

Instance Method Summary collapse

Instance Method Details

#confirm_request(name) ⇒ Object



259
260
261
262
263
264
265
266
# File 'lib/kuali-sakai-common-lib/profile2.rb', line 259

def confirm_request(name)
  frm.div(:class=>"connection", :text=>name).link(:title=>"Confirm connection request").click
  frm.div(:class=>"modalWindowButtons").wait_until_present
  frm.div(:class=>"modalWindowButtons").button(:value=>"Confirm connection request").click
  frm.div(:class=>"modalWindowButtons").wait_while_present
  sleep 0.5
  Profile2Connections.new @browser
end

#connectionsObject

Returns an array containing the names of the connected users.



269
270
271
272
273
274
275
276
277
# File 'lib/kuali-sakai-common-lib/profile2.rb', line 269

def connections
  results = []
  frm.div(:class=>"portletBody").spans.each do |span|
    if span.class_name == "connection-info-name"
      results << span.text
    end
  end
  return results
end