Proyectos de Subversion Moodle

Rev

| Ultima modificación | Ver Log |

Rev Autor Línea Nro. Línea
1441 ariadna 1
@core @core_grades
2
Feature: Custom scales can be used to rate forum discussions
3
  In order to ensure custom scales are displayed in the gradebook
4
  As a teacher
5
  I need to create a new custom scale, rate a student post in a forum
6
 
7
  Background:
8
    Given the following "courses" exist:
9
      | fullname | shortname |
10
      | Course 1 | C1        |
11
    And the following "users" exist:
12
      | username | firstname | lastname | email                |
13
      | teacher1 | Teacher   | 1        | teacher1@example.com |
14
      | student1 | Student   | 1        | student1@example.com |
15
    And the following "course enrolments" exist:
16
      | user     | course | role           |
17
      | teacher1 | C1     | editingteacher |
18
      | student1 | C1     | student        |
19
    And the following "activities" exist:
20
      | activity | course | name    | idnumber |
21
      | forum    | C1     | Forum 1 | forum1   |
22
    And the following "mod_forum > discussions" exist:
23
      | user     | forum  | name         | message              |
24
      | student1 | forum1 | Discussion 1 | Discussion 1 message |
25
    And the following "scales" exist:
26
      | name        | scale                   |
27
      | CustomScale | Bad,OK,Pretty Good,Good |
28
    And I am on the "Forum 1" "forum activity editing" page logged in as teacher1
29
    And I expand all fieldsets
30
    And I set the field "assessed" to "Average of ratings"
31
    And I set the field "scale[modgrade_type]" to "Scale"
32
    And I set the field "scale[modgrade_scale]" to "CustomScale"
33
    And I press "Save and display"
34
 
35
  @javascript
36
  Scenario Outline: Verify that scales are displayed in the gradebook after rating a forum discussion
37
    Given I follow "Discussion 1"
38
    And I set the field "rating" to "<scalescores>"
39
    When I am on the "Course 1" "grades > Grader report > View" page
40
    Then the following should exist in the "user-grades" table:
41
      | -1-       | -2-                  | -3-           |
42
      | Student 1 | student1@example.com | <scalescores> |
43
    And I am on the "Course 1" "grades > User report > View" page logged in as student1
44
    And "Forum 1 rating" row "Grade" column of "user-grade" table should contain "<scalescores>"
45
 
46
    Examples:
47
      | scalescores |
48
      | Bad         |
49
      | OK          |
50
      | Pretty Good |
51
      | Good        |