1 |
efrain |
1 |
@core @core_grades
|
|
|
2 |
Feature: Site settings can be used to hide parts of the gradebook UI
|
|
|
3 |
In order to hide UI elements
|
|
|
4 |
As an admin
|
|
|
5 |
I need to modify gradebook related system settings
|
|
|
6 |
|
|
|
7 |
Background:
|
|
|
8 |
Given the following "courses" exist:
|
|
|
9 |
| fullname | shortname | category | format |
|
|
|
10 |
| Course 1 | C1 | 0 | topics |
|
|
|
11 |
And the following "users" exist:
|
|
|
12 |
| username | firstname | lastname | email | idnumber |
|
|
|
13 |
| student1 | Student | 1 | student1@example.com | s1 |
|
|
|
14 |
And the following "course enrolments" exist:
|
|
|
15 |
| user | course | role |
|
|
|
16 |
| student1 | C1 | student |
|
|
|
17 |
And the following "activities" exist:
|
|
|
18 |
| activity | course | idnumber | name | intro |
|
|
|
19 |
| assign | C1 | assign1 | Assignment1 | Assignment 1 intro |
|
|
|
20 |
And I am on the "Course 1" "grades > Grader report > View" page logged in as "admin"
|
|
|
21 |
And I turn editing mode on
|
|
|
22 |
|
|
|
23 |
@javascript
|
|
|
24 |
Scenario: Hide minimum grade
|
|
|
25 |
Given I click on grade item menu "Assignment1" of type "gradeitem" on "grader" page
|
|
|
26 |
When I choose "Edit grade item" in the open action menu
|
|
|
27 |
And I should see "Minimum grade"
|
|
|
28 |
And I click on "Cancel" "button" in the "Edit grade item" "dialogue"
|
|
|
29 |
Then I navigate to "Grades > General settings" in site administration
|
|
|
30 |
And I set the field "Show minimum grade" to "0"
|
|
|
31 |
And I press "Save changes"
|
|
|
32 |
And I am on the "Course 1" "grades > Grader report > View" page
|
|
|
33 |
And I click on grade item menu "Assignment1" of type "gradeitem" on "grader" page
|
|
|
34 |
And I choose "Edit grade item" in the open action menu
|
|
|
35 |
And I should not see "Minimum grade"
|
|
|
36 |
|
|
|
37 |
@javascript
|
|
|
38 |
Scenario: Disable category overriding
|
|
|
39 |
Given "Student 1 Course total" "field" should exist
|
|
|
40 |
And I navigate to "Grades > Grade category settings" in site administration
|
|
|
41 |
And I set the field "Allow category grades to be manually overridden" to "0"
|
|
|
42 |
And I press "Save changes"
|
|
|
43 |
When I am on the "Course 1" "grades > Grader report > View" page
|
|
|
44 |
Then "Student 1 Course total" "field" should not exist
|