Class: AssessmentTotalScores
- Defined in:
- lib/sambal-cle/page_objects/assessments.rb
Overview
Instructor’s view of Students’ assessment scores
Instance Method Summary collapse
-
#comment_in_first_box=(comment) ⇒ Object
Enters the specified string into the topmost box listed on the page.
-
#student_ids ⇒ Object
Gets the user ids listed in the scores table, returns them as an Array object.
Methods inherited from BasePage
basic_page_elements, button, damballa, frame_element, link
Instance Method Details
#comment_in_first_box=(comment) ⇒ Object
Enters the specified string into the topmost box listed on the page.
This method is especially useful when the student identities are obscured, since in that situation you can’t target a specific student’s comment box, obviously.
328 329 330 |
# File 'lib/sambal-cle/page_objects/assessments.rb', line 328 def comment_in_first_box=(comment) frm.text_field(:name=>"editTotalResults:totalScoreTable:0:_id345").value=comment end |
#student_ids ⇒ Object
Gets the user ids listed in the scores table, returns them as an Array object.
Note that this method is only appropriate when student identities are not being obscured on this page. If student submissions are set to be anonymous then this method will fail to return any ids.
300 301 302 303 304 305 306 |
# File 'lib/sambal-cle/page_objects/assessments.rb', line 300 def student_ids ids = [] scores_table = frm.table(:id=>"editTotalResults:totalScoreTable").to_a scores_table.delete_at(0) scores_table.each { |row| ids << row[1] } ids end |