MDL-58265 core_test: replace I turn editing on steps

Also remove few more unnecessary steps that redirects behat to
site home page to actually get to the course.

Part of MDL-55611 epic.
This commit is contained in:
Simey Lameze 2017-03-15 15:13:09 +08:00 committed by Damyon Wiese
parent 3353cfd8c1
commit fdeeaff954
458 changed files with 1697 additions and 2148 deletions

View file

@ -9,11 +9,10 @@ Feature: Highlight non-inherited permissions
| fullname | shortname |
| Course fullname | C_shortname |
And I log in as "admin"
And I am on site homepage
@javascript
Scenario: Override a permission
Given I am on course page "Course fullname"
Given I am on "Course fullname" course homepage
And I navigate to "Users > Permissions" in current page administration
And I select "Manager (0)" from the "roleid" singleselect
And I click on "Prohibit" "radio" in the "View added and updated modules in recent activity block" "table_row"

View file

@ -49,9 +49,7 @@ Feature: Manage availability conditions
# OK, toggling works. Set the grade one to Hide and we'll go see if it actually worked.
And I click on "Hide" "icon" in the "Restriction by grade" "table_row"
And I am on site homepage
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Page" to section "1"
And I expand all fieldsets
And I click on "Add restriction..." "button"

View file

@ -57,7 +57,7 @@ Feature: Set up contextual data for tests
| Grouping 1 | C1 | GG1 |
| Grouping 2 | C1 | GG2 |
When I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Users > Groups" in current page administration
Then I should see "Group 1"
And I should see "Group 2"
@ -86,7 +86,7 @@ Feature: Set up contextual data for tests
| mod/forum:editanypost | Allow | student | Course | C1 |
| mod/forum:replynews | Prevent | editingteacher | Course | C1 |
When I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Users > Permissions" in current page administration
And I set the field "Advanced role override" to "Student (1)"
Then "mod/forum:editanypost" capability has "Allow" permission
@ -106,7 +106,7 @@ Feature: Set up contextual data for tests
| user | course | role |
| student1 | C1 | student |
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Topic 1"
Scenario: Add role assigns
@ -142,20 +142,20 @@ Feature: Set up contextual data for tests
Then "Edit settings" "link" should exist in current page administration
And I log out
And I log in as "user2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And "Turn editing on" "link" should exist in current page administration
And I log out
And I log in as "user3"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And "Turn editing on" "link" should exist in current page administration
And I log out
And I log in as "user4"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And "Turn editing on" "link" should exist in current page administration
And I log out
And I log in as "user5"
And I should see "You are logged in as"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "You can not enrol yourself in this course."
Scenario: Add modules
@ -193,7 +193,7 @@ Feature: Set up contextual data for tests
| activity | name | intro | course | idnumber | grade |
| assign | Test assignment name with scale | Test assignment description | C1 | assign1 | Test Scale 1 |
When I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Test assignment name"
# Assignment 2.2 module type is disabled by default
# And I should see "Test assignment22 name"
@ -254,7 +254,7 @@ Feature: Set up contextual data for tests
| grouping | group |
| GG1 | G1 |
When I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Users > Groups" in current page administration
Then the "groups" select box should contain "Group 1 (1)"
And the "groups" select box should contain "Group 2 (1)"
@ -313,7 +313,7 @@ Feature: Set up contextual data for tests
| Grade sub category 2 | C1 | Grade category 1 |
When I log in as "admin"
And I am on course index
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
Then I should see "Grade category 1"
And I should see "Grade sub category 2"
@ -336,7 +336,7 @@ Feature: Set up contextual data for tests
| Test Grade Item 2 | C1 | Grade category 1 |
| Test Grade Item 3 | C1 | Grade sub category 2 |
When I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Setup > Gradebook setup" in the course gradebook
Then I should see "Test Grade Item 1"
And I follow "Edit Test Grade Item 1"
@ -364,7 +364,7 @@ Feature: Set up contextual data for tests
| name | scale |
| Test Scale 1 | Disappointing, Good, Very good, Excellent |
When I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Scales" in the course gradebook
Then I should see "Test Scale 1"
And I should see "Disappointing, Good, Very good, Excellent"
@ -385,7 +385,7 @@ Feature: Set up contextual data for tests
And the following config values are set as admin:
| enableoutcomes | 1 |
When I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Outcomes"
Then I should see "Grade outcome 1" in the "#addoutcomes" "css_element"
And I should see "Grade outcome 2" in the "#removeoutcomes" "css_element"
@ -413,7 +413,7 @@ Feature: Set up contextual data for tests
And the following config values are set as admin:
| enableoutcomes | 1 |
When I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Setup > Gradebook setup" in the course gradebook
Then I should see "Test Outcome Grade Item 1"
And I follow "Edit Test Outcome Grade Item 1"
@ -430,5 +430,5 @@ Feature: Set up contextual data for tests
| blockname | contextlevel | reference | pagetypepattern | defaultregion |
| online_users | Course | C1 | course-view-* | site-pre |
When I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Online users"

View file

@ -19,7 +19,7 @@ Feature: Transform date time string arguments
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment name"
And I should see "##yesterday##l, j F Y##"
And I log out

View file

@ -31,7 +31,7 @@ Feature: Edit capabilities
Scenario: Course capabilities overrides
Given I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Users > Permissions" in current page administration
And I override the system permissions of "Student" role with:
| mod/forum:deleteanypost | Prohibit |
@ -45,8 +45,7 @@ Feature: Edit capabilities
Scenario: Module capabilities overrides
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Forum" to section "1" and I fill the form with:
| Forum name | I'm the name |
| Description | I'm the introduction |

View file

@ -33,7 +33,7 @@ Feature: Verify that all form fields values can be get and set
| activity | course | idnumber | name | intro | firstpagetitle | wikimode | visible |
| wiki | C1 | wiki1 | Test this one | Test this one | Test this one | collaborative | 0 |
And I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Reset" node in "Course administration"
# Select (multi-select) - Checking "the select box should contain".
And I expand all fieldsets
@ -47,8 +47,7 @@ Feature: Verify that all form fields values can be get and set
And the "Unenrol users" select box should not contain "President"
And the "Unenrol users" select box should not contain "Baker"
And the "Unenrol users" select box should not contain "President, Baker"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I follow "Test this one"
And I press "Create page"
# Text (textarea & editor) & Select (multi-select) - Checking "I set the following fields to these values".
@ -98,7 +97,7 @@ Feature: Verify that all form fields values can be get and set
| Default format | HTML |
| Force format | 1 |
And I press "Cancel"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Radio - Checking "I set the field" and "the field matches value".
And I add a "Choice" to section "1" and I fill the form with:
| Choice name | Test choice name |
@ -113,7 +112,7 @@ Feature: Verify that all form fields values can be get and set
And the field "one" matches value "1"
And the field "two" matches value ""
# Check if field xpath set/match works.
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" node in "Course administration"
And I set the field with xpath "//input[@id='id_idnumber']" to "Course id number"
And the field with xpath "//input[@name='idnumber']" matches value "Course id number"
@ -126,7 +125,7 @@ Feature: Verify that all form fields values can be get and set
@javascript
Scenario: with JS enabled all form fields getters and setters works as expected
Then I am on course page "Course 1"
Then I am on "Course 1" course homepage
And I navigate to "Users > Groups" in current page administration
# Select (multi-select & AJAX) - Checking "I set the field" and "select box should contain".
And I set the field "groups" to "Group 2"
@ -138,7 +137,7 @@ Feature: Verify that all form fields values can be get and set
And the "members" select box should contain "Student 2"
And the "members" select box should not contain "Student 3"
# Checkbox (AJAX) - Checking "I set the field" and "I set the following fields to these values".
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a "Lesson" to section "1"
And I set the following fields to these values:
| Name | Test lesson |

View file

@ -23,9 +23,7 @@ Feature: Forms manipulation
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And I log in as "admin"
And I am on site homepage
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Quiz" to section "1"
When I expand all fieldsets
Then I should see "Close the quiz"

View file

@ -120,9 +120,7 @@ Feature: Add customised file types
| Custom description | Froggy file |
And I press "Save changes"
# Create a resource activity and add it to a course
And I am on site homepage
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add a "File" to section "1"
And I set the following fields to these values:
| Name | An example of customised file type |

View file

@ -18,7 +18,7 @@ Feature: tool_monitor_rule
And I navigate to "Event monitoring rules" node in "Site administration > Reports"
And I click on "Enable" "link"
And I am on site homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Event monitoring rules" node in "Course administration > Reports"
And I press "Add a new rule"
And I set the following fields to these values:
@ -45,8 +45,7 @@ Feature: tool_monitor_rule
Scenario: Add a rule on course level
Given I log in as "teacher1"
And I am on site homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Event monitoring rules" node in "Course administration > Reports"
When I press "Add a new rule"
And I set the following fields to these values:
@ -66,7 +65,7 @@ Feature: tool_monitor_rule
Scenario: Delete a rule on course level
Given I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Event monitoring rules" node in "Course administration > Reports"
When I click on "Delete rule" "link"
Then I should see "Are you sure you want to delete the rule \"New rule course level\"?"
@ -76,7 +75,7 @@ Feature: tool_monitor_rule
Scenario: Edit a rule on course level
Given I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Event monitoring rules" node in "Course administration > Reports"
When I click on "Edit rule" "link"
And I set the following fields to these values:
@ -95,7 +94,7 @@ Feature: tool_monitor_rule
Scenario: Duplicate a rule on course level
Given I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Event monitoring rules" node in "Course administration > Reports"
When I click on "Duplicate rule" "link" in the "New rule course level" "table_row"
Then I should see "Rule successfully duplicated"
@ -154,7 +153,7 @@ Feature: tool_monitor_rule
Scenario: Duplicate a rule on site level
Given I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Event monitoring rules" node in "Course administration > Reports"
When I click on "Duplicate rule" "link" in the "New rule site level" "table_row"
Then I should see "Rule successfully duplicated"

View file

@ -22,7 +22,7 @@ Feature: tool_monitor_subscriptions
And I log in as "admin"
And I navigate to "Event monitoring rules" node in "Site administration > Reports"
And I click on "Enable" "link"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Event monitoring rules" node in "Course administration > Reports"
And I press "Add a new rule"
And I set the following fields to these values:
@ -131,7 +131,7 @@ Feature: tool_monitor_subscriptions
And I follow "Subscribe to rule \"New rule course level\""
And I should see "Subscription successfully created"
And "#toolmonitorsubs_r0" "css_element" should exist
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I trigger cron
And I am on site homepage
When I click on ".popover-region-notifications" "css_element"

View file

@ -23,8 +23,7 @@ Feature: Backup user data
@javascript
Scenario: Delete and restore a quiz with user data
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Quiz" to section "1" and I fill the form with:
| Name | Quiz 1 |
| Description | Test quiz description |
@ -44,7 +43,7 @@ Feature: Backup user data
| Feedback for the response 'False'. | So you think it is false |
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Quiz 1"
And I press "Attempt quiz now"
And I click on "True" "radio" in the "First question" "question"
@ -55,8 +54,7 @@ Feature: Backup user data
And I should see "5.00 out of 10.00"
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I delete "Quiz 1" activity
And I run all adhoc tasks
And I navigate to "Recycle bin" node in "Course administration"
@ -64,7 +62,7 @@ Feature: Backup user data
And I click on "Restore" "link" in the "region-main" "region"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
When I navigate to "User report" in the course gradebook
Then "Quiz 1" row "Grade" column of "user-grade" table should contain "5"
And "Quiz 1" row "Percentage" column of "user-grade" table should contain "50"

View file

@ -25,8 +25,7 @@ Feature: Basic recycle bin functionality
Scenario: Restore a deleted assignment
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assign |
| Description | Test |
@ -37,8 +36,7 @@ Feature: Basic recycle bin functionality
And I click on "Restore" "link" in the "region-main" "region"
And I should see "'Test assign' has been restored"
And I wait to be redirected
And I am on homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Test assign" in the "Topic 1" "section"
Scenario: Restore a deleted course
@ -64,8 +62,7 @@ Feature: Basic recycle bin functionality
@javascript
Scenario: Deleting a single item from the recycle bin
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assign |
| Description | Test |
@ -84,8 +81,7 @@ Feature: Basic recycle bin functionality
@javascript
Scenario: Deleting all the items from the recycle bin
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assign 1 |
| Description | Test 1 |

View file

@ -33,7 +33,7 @@ Feature: Upload users
And I should see "Tom Jones"
And I should see "Trent Reznor"
And I should see "reznor@example.com"
And I am on course page "Maths"
And I am on "Maths" course homepage
And I navigate to "Users > Groups" in current page administration
And I set the field "groups" to "Section 1 (1)"
And the "members" select box should contain "Tom Jones"

View file

@ -20,7 +20,7 @@ Feature: Add a new user tour
| Display in middle of page | Welcome | Welcome to your personal learning space. We'd like to give you a quick tour to show you some of the areas you may find helpful |
And I add steps to the "First tour" tour:
| targettype | targetvalue_block | Title | Content |
| Block | Course overview | Course overview | This area shows you what's happening in some of your courses |
| Block | My overview | My overview | This area shows you what's happening in some of your courses |
| Block | Calendar | Calendar | This is the Calendar. All of your assignments and due dates can be found here |
And I add steps to the "First tour" tour:
| targettype | targetvalue_selector | Title | Content |

View file

@ -46,17 +46,14 @@ Feature: Apply tour filters to a tour
| Display in middle of page | Welcome | Welcome to your course tour.|
And I log out
And I log in as "editor1"
And I am on site homepage
When I am on course page "Course 1"
When I am on "Course 1" course homepage
Then I should not see "Welcome to your course tour."
And I log out
And I log in as "student1"
And I am on site homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Welcome to your course tour."
And I click on "End tour" "button"
And I log out
And I log in as "teacher1"
And I am on site homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Welcome to your course tour."

View file

@ -21,8 +21,7 @@ Feature: availability_completion
Scenario: Test condition
# Basic setup.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
# Add a Page with a completion tickbox.
And I add a "Page" to section "1" and I fill the form with:
@ -47,7 +46,7 @@ Feature: availability_completion
# Log back in as student.
When I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Page 2 should not appear yet.
Then I should not see "Page 2" in the "region-main" "region"

View file

@ -19,7 +19,7 @@ Feature: Confirm that conditions on completion no longer cause a bug
Scenario: Multiple completion conditions on glossary
# Set up course.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" node in "Course administration"
And I expand all fieldsets
And I set the field "Enable completion tracking" to "Yes"

View file

@ -21,8 +21,7 @@ Feature: availability_date
Scenario: Test condition
# Basic setup.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
# Add a Page with a date condition that does match (from the past).
And I add a "Page" to section "1"
@ -54,7 +53,7 @@ Feature: availability_date
# Log back in as student.
When I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Page 1 should appear, but page 2 does not.
Then I should see "Page 1" in the "region-main" "region"

View file

@ -21,8 +21,7 @@ Feature: availability_grade
Scenario: Test condition
# Basic setup.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
# Add an assignment.
And I add a "Assignment" to section "1" and I fill the form with:
@ -70,7 +69,7 @@ Feature: availability_grade
And I click on "Edit settings" "link" in the "P3" activity
And I expand all fieldsets
And the field "Maximum grade percentage (exclusive)" matches value ""
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Add a Page with a grade condition for 10%.
And I add a "Page" to section "4"
@ -90,7 +89,7 @@ Feature: availability_grade
# Log in as student without a grade yet.
When I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Do the assignment.
And I follow "A1"
@ -108,7 +107,7 @@ Feature: availability_grade
# Log back in as teacher.
When I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Give the assignment 40%.
And I follow "A1"
@ -123,7 +122,7 @@ Feature: availability_grade
# Log back in as student.
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Check pages are visible.
Then I should see "P2" in the "region-main" "region"

View file

@ -21,8 +21,7 @@ Feature: availability_group
Scenario: Test condition
# Basic setup.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
# Start to add a Page. If there aren't any groups, there's no Group option.
And I add a "Page" to section "1"
@ -38,7 +37,7 @@ Feature: availability_group
| G2 | C1 | GI2 |
# This step used to be 'And I follow "C1"', but Chrome thinks the breadcrumb
# is not clickable, so we'll go via the home page instead.
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a "Page" to section "1"
And I expand all fieldsets
And I click on "Add restriction..." "button"
@ -83,7 +82,7 @@ Feature: availability_group
# Log back in as student.
When I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# No pages should appear yet.
Then I should not see "P1" in the "region-main" "region"
@ -96,7 +95,7 @@ Feature: availability_group
| student1 | GI1 |
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# P1 (any groups) and P2 should show but not P3.
Then I should see "P1" in the "region-main" "region"

View file

@ -27,8 +27,7 @@ Feature: availability_grouping
Scenario: Test condition
# Basic setup.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
# Start to add a Page. If there aren't any groupings, there's no Grouping option.
And I add a "Page" to section "1"
@ -40,7 +39,7 @@ Feature: availability_grouping
# Back to course page but add groups.
# This step used to be 'And I follow "C1"', but Chrome thinks the breadcrumb
# is not clickable, so we'll go via the home page instead.
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And the following "groupings" exist:
| name | course | idnumber |
| GX1 | C1 | GXI1 |
@ -76,7 +75,7 @@ Feature: availability_grouping
# Log back in as student.
When I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# No pages should appear yet.
Then I should not see "P1" in the "region-main" "region"
@ -88,7 +87,7 @@ Feature: availability_grouping
| grouping | group |
| GXI1 | GI1 |
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# P1 should show but not B2.
Then I should see "P1" in the "region-main" "region"

View file

@ -21,8 +21,7 @@ Feature: availability_profile
Scenario: Test condition
# Basic setup.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
# Add
And I add a "Page" to section "1"
@ -55,7 +54,7 @@ Feature: availability_profile
# Log back in as student.
When I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# I see P1 but not P2.
Then I should see "P1" in the "region-main" "region"
@ -80,8 +79,7 @@ Feature: availability_profile
And I click on "Update profile" "button"
# Set Page activity which has requirement on this field.
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Page" to section "1"
And I set the following fields to these values:
| Name | P1 |
@ -106,5 +104,5 @@ Feature: availability_profile
# Log out and back in as student. Should be able to see activity.
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "P1" in the "region-main" "region"

View file

@ -39,8 +39,7 @@ Feature: display_availability
Scenario: Activity availability display
# Set up.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
# Add a Page with 1 restriction.
When I add a "Page" to section "1"
@ -101,7 +100,7 @@ Feature: display_availability
# Change to student view.
Given I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Page 1 display still there but should be dimmed and not a link.
Then I should see "Page 1" in the "#section-1 .dimmed_text" "css_element"
@ -121,8 +120,7 @@ Feature: display_availability
Scenario: Section availability display
# Set up.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
# Add a restriction to section 1 (visible to students).
When I edit the section "1"
@ -144,7 +142,7 @@ Feature: display_availability
And I press "Save changes"
# This is necessary because otherwise it fails in Chrome, see MDL-44959
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Add Pages to each section.
And I add a "Page" to section "1" and I fill the form with:
@ -168,7 +166,7 @@ Feature: display_availability
# Change to student view.
Given I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# The contents of both sections should be hidden.
Then I should not see "Page 1" in the "region-main" "region"

View file

@ -32,8 +32,7 @@ Feature: edit_availability
Given the following config values are set as admin:
| enableavailability | 0 |
When I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Page" to section "1"
Then "Restrict access" "fieldset" should not exist
@ -44,7 +43,7 @@ Feature: edit_availability
And the following config values are set as admin:
| enableavailability | 1 |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a "Page" to section "1"
Then "Restrict access" "fieldset" should exist
@ -56,10 +55,7 @@ Feature: edit_availability
Scenario: Edit availability using settings in activity form
# Set up.
Given I log in as "teacher1"
And I am on course page "Course 1"
# Add a Page and check it has None in so far.
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Page" to section "1"
And I expand all fieldsets
Then I should see "None" in the "Restrict access" "fieldset"
@ -147,8 +143,7 @@ Feature: edit_availability
Scenario: Edit availability using settings in section form
# Set up.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
# Edit a section
When I edit the section "1"
@ -168,8 +163,7 @@ Feature: edit_availability
Given the following config values are set as admin:
| enableavailability | 0 |
And I log in as "admin"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Forum" to section "1"
When I expand all fieldsets
Then "Add group/grouping access restriction" "button" should not exist
@ -181,8 +175,7 @@ Feature: edit_availability
| name | course | idnumber |
| GX1 | C1 | GXI1 |
And I log in as "admin"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Forum" to section "1"
And I set the following fields to these values:
| Forum name | MyForum |

View file

@ -15,8 +15,7 @@ Feature: Duplicate activities
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Database" to section "1" and I fill the form with:
| Name | Test database name |
| Description | Test database description |

View file

@ -17,8 +17,7 @@ Feature: Import course's contents into another course
| teacher1 | C1 | editingteacher |
| teacher1 | C2 | editingteacher |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Database" to section "1" and I fill the form with:
| Name | Test database name |
| Description | Test database description |

View file

@ -25,7 +25,7 @@ Feature: Option to include groups and groupings when importing a course to anoth
| Grouping 1 | C1 | GROUPING1 |
| Grouping 2 | C1 | GROUPING2 |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Include groups and groupings when importing a course to another course
Given I import "Course 1" course into "Course 2" course using this options:

View file

@ -15,8 +15,7 @@ Feature: Restore Moodle 2 course backups
| assign | C3 | assign1 | Test assign name | Assign description | 1 |
| data | C3 | data1 | Test database name | Database description | 2 |
And I log in as "admin"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Forum" to section "1" and I fill the form with:
| Forum name | Test forum name |
| Description | Test forum description |
@ -62,7 +61,7 @@ Feature: Restore Moodle 2 course backups
Scenario: Restore a backup into the same course removing it's contents before that
When I backup "Course 1" course using this options:
| Confirmation | Filename | test_backup.mbz |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a "Forum" to section "1" and I fill the form with:
| Forum name | Test forum post backup name |
| Description | Test forum post backup description |

View file

@ -86,7 +86,7 @@ Feature: Award badges
| student1 | C1 | student |
| student2 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Add a new badge" node in "Course administration > Badges"
And I follow "Add a new badge"
And I set the following fields to these values:
@ -106,7 +106,7 @@ Feature: Award badges
And I press "Award badge"
And I set the field "potentialrecipients[]" to "Student 1 (student1@example.com)"
When I press "Award badge"
And I am on course page "Course Badge"
And I follow "Course Badge"
Then I should see "Recipients (2)"
And I log out
And I log in as "student1"
@ -128,7 +128,7 @@ Feature: Award badges
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" node in "Course administration"
And I set the following fields to these values:
| Enable completion tracking | Yes |
@ -137,7 +137,7 @@ Feature: Award badges
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment name |
| Description | Submit your online text |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Add a new badge" node in "Course administration > Badges"
And I follow "Add a new badge"
And I set the following fields to these values:
@ -156,8 +156,7 @@ Feature: Award badges
And I follow "Profile" in the user menu
And I click on "Course 1" "link" in the "region-main" "region"
Then I should not see "badges"
And I am on homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I press "Mark as complete: Test assignment name"
And I follow "Profile" in the user menu
And I click on "Course 1" "link" in the "region-main" "region"
@ -177,7 +176,7 @@ Feature: Award badges
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" node in "Course administration"
And I set the following fields to these values:
| Enable completion tracking | Yes |
@ -192,7 +191,7 @@ Feature: Award badges
And I click on "Condition: Activity completion" "link"
And I set the field "Assignment - Test assignment name" to "1"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Add a new badge" node in "Course administration > Badges"
And I follow "Add a new badge"
And I set the following fields to these values:
@ -211,8 +210,7 @@ Feature: Award badges
And I follow "Profile" in the user menu
And I click on "Course 1" "link" in the "region-main" "region"
Then I should not see "badges"
And I am on homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Not completed: Test assignment name. Select to mark as complete." "icon"
And I log out
# Completion cron won't mark the whole course completed unless the
@ -242,7 +240,7 @@ Feature: Award badges
| student1 | C1 | student |
| student2 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Create course badge 1.
And I navigate to "Add a new badge" node in "Course administration > Badges"
And I follow "Add a new badge"
@ -325,7 +323,7 @@ Feature: Award badges
| student1 | C1 | student |
| student2 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Add a new badge" node in "Course administration > Badges"
And I follow "Add a new badge"
And I set the following fields to these values:
@ -345,7 +343,7 @@ Feature: Award badges
And I press "Award badge"
And I set the field "potentialrecipients[]" to "Student 1 (student1@example.com)"
When I press "Award badge"
And I am on course page "Course Badge"
And I follow "Course Badge"
Then I should see "Recipients (2)"
And I follow "Recipients (2)"
And I press "Award badge"
@ -353,5 +351,5 @@ Feature: Award badges
And I press "Revoke badge"
And I set the field "existingrecipients[]" to "Student 1 (student1@example.com)"
When I press "Revoke badge"
And I am on course page "Course Badge"
And I follow "Course Badge"
Then I should see "Recipients (0)"

View file

@ -110,48 +110,47 @@ Feature: Block activity modules
When I log in as "admin"
And I am on course index
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Activities" block
And I click on "Assignments" "link" in the "Activities" "block"
Then I should see "Test assignment name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Chats" "link" in the "Activities" "block"
And I should see "Test chat name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Choices" "link" in the "Activities" "block"
And I should see "Test choice name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Databases" "link" in the "Activities" "block"
And I should see "Test database name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Feedback" "link" in the "Activities" "block"
And I should see "Test feedback name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Forums" "link" in the "Activities" "block"
And I should see "Test forum name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "External tools" "link" in the "Activities" "block"
And I should see "Test lti name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Quizzes" "link" in the "Activities" "block"
And I should see "Test quiz name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Glossaries" "link" in the "Activities" "block"
And I should see "Test glossary name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "SCORM packages" "link" in the "Activities" "block"
And I should see "Test scorm name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Lessons" "link" in the "Activities" "block"
And I should see "Test lesson name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Wikis" "link" in the "Activities" "block"
And I should see "Test wiki name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Workshop" "link" in the "Activities" "block"
And I should see "Test workshop name"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Resources" "link" in the "Activities" "block"
And I should see "Test book name"
And I should see "Test page name"

View file

@ -25,30 +25,29 @@ Feature: The activity results block displays student scores
| student4 | C1 | student |
| student5 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment 1 |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment 2 |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment 3 |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a "Page" to section "1"
And I set the following fields to these values:
| Name | Test page name |
| Description | Test page description |
| Page content | This is a page |
And I press "Save and return to course"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Test page name"
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
@ -58,7 +57,7 @@ Feature: The activity results block displays student scores
And I give the grade "60.00" to the user "Student 4" for the grade item "Test assignment 1"
And I give the grade "50.00" to the user "Student 5" for the grade item "Test assignment 1"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Configure the block on a non-graded activity to show 3 high scores
Given I follow "Test page name"
@ -84,19 +83,19 @@ Feature: The activity results block displays student scores
And I configure the "Activity results" block
Then the field "id_config_activitygradeitemid" matches value "Test assignment 1"
And I press "Cancel"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 2"
And I add the "Activity results" block
And I configure the "Activity results" block
And the field "id_config_activitygradeitemid" matches value "Test assignment 2"
And I press "Cancel"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 3"
And I add the "Activity results" block
And I configure the "Activity results" block
And the field "id_config_activitygradeitemid" matches value "Test assignment 3"
And I press "Cancel"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test page name"
And I add the "Activity results" block
And I configure the "Activity results" block

View file

@ -15,8 +15,7 @@ Feature: The activity results block doesn't displays student scores for unconfig
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
Scenario: Add the block to a the course
Given I add the "Activity results" block

View file

@ -15,8 +15,7 @@ Feature: The activity results block doesn't display student scores for unsupport
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
Scenario: Try to configure the block to use an activity without grades
Given I add a "Assignment" to section "1" and I fill the form with:

View file

@ -24,13 +24,12 @@ Feature: The activity results block can have administrator set defaults
| config_gradeformat | 2 | block_activity_results |
| config_nameformat | 2 | block_activity_results |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add the "Activity results" block
When I configure the "Activity results" block
And the following fields match these values:
@ -48,13 +47,12 @@ Feature: The activity results block can have administrator set defaults
| config_showworst | 0 | block_activity_results |
| config_showworst_locked | 1 | block_activity_results |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add the "Activity results" block
When I configure the "Activity results" block
And the following fields match these values:

View file

@ -25,13 +25,12 @@ Feature: The activity results block displays student high scores
| student4 | C1 | student |
| student5 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
And I give the grade "90.00" to the user "Student 1" for the grade item "Test assignment"
@ -40,7 +39,7 @@ Feature: The activity results block displays student high scores
And I give the grade "60.00" to the user "Student 4" for the grade item "Test assignment"
And I give the grade "50.00" to the user "Student 5" for the grade item "Test assignment"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Configure the block on the course page to show 0 high scores
Given I add the "Activity results" block

View file

@ -25,22 +25,21 @@ Feature: The activity results block displays students high scores in group as sc
| student4 | C1 | student |
| student5 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Scales" in the course gradebook
And I press "Add a new scale"
And I set the following fields to these values:
| Name | My Scale |
| Scale | Disappointing, Not good enough, Average, Good, Very good, Excellent! |
And I press "Save changes"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
| id_grade_modgrade_type | Scale |
| id_grade_modgrade_scale | My Scale |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
And I give the grade "Excellent!" to the user "Student 1" for the grade item "Test assignment"
@ -49,7 +48,7 @@ Feature: The activity results block displays students high scores in group as sc
And I give the grade "Average" to the user "Student 4" for the grade item "Test assignment"
And I give the grade "Not good enough" to the user "Student 5" for the grade item "Test assignment"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Configure the block on the course page to show 1 high score
Given I add the "Activity results" block

View file

@ -42,15 +42,14 @@ Feature: The activity results block displays student in group high scores as sca
| student5 | G3 |
| student6 | G3 |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Scales" in the course gradebook
And I press "Add a new scale"
And I set the following fields to these values:
| Name | My Scale |
| Scale | Disappointing, Not good enough, Average, Good, Very good, Excellent! |
And I press "Save changes"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
@ -58,7 +57,7 @@ Feature: The activity results block displays student in group high scores as sca
| id_grade_modgrade_type | Scale |
| id_grade_modgrade_scale | My Scale |
| Group mode | Separate groups |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
And I give the grade "Excellent!" to the user "Student 1" for the grade item "Test assignment"
@ -68,7 +67,7 @@ Feature: The activity results block displays student in group high scores as sca
And I give the grade "Good" to the user "Student 5" for the grade item "Test assignment"
And I give the grade "Average" to the user "Student 6" for the grade item "Test assignment"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Try to configure the block on the course page to show 1 high score
Given I add the "Activity results" block
@ -83,7 +82,7 @@ Feature: The activity results block displays student in group high scores as sca
And I should see "Excellent!" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 1" in the "Activity results" "block"
And I should see "Excellent!" in the "Activity results" "block"
@ -104,7 +103,7 @@ Feature: The activity results block displays student in group high scores as sca
And I should see "Good" in the "Activity results" "block"
And I log out
And I log in as "student3"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 3" in the "Activity results" "block"
And I should see "Very good" in the "Activity results" "block"
And I should see "Student 4" in the "Activity results" "block"
@ -125,7 +124,7 @@ Feature: The activity results block displays student in group high scores as sca
And I should see "Good" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "User S1" in the "Activity results" "block"
And I should see "Excellent!" in the "Activity results" "block"
And I should see "User S2" in the "Activity results" "block"
@ -146,7 +145,7 @@ Feature: The activity results block displays student in group high scores as sca
And I should see "Good" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "User" in the "Activity results" "block"
And I should see "Excellent!" in the "Activity results" "block"
And I should see "Very good" in the "Activity results" "block"

View file

@ -42,14 +42,13 @@ Feature: The activity results block displays student in separate groups scores
| student5 | G3 |
| student6 | G3 |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
| Group mode | Separate groups |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
And I give the grade "100.00" to the user "Student 1" for the grade item "Test assignment"
@ -59,7 +58,7 @@ Feature: The activity results block displays student in separate groups scores
And I give the grade "80.00" to the user "Student 5" for the grade item "Test assignment"
And I give the grade "70.00" to the user "Student 6" for the grade item "Test assignment"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Configure the block on the course page to show 1 high score
Given I add the "Activity results" block
@ -89,7 +88,7 @@ Feature: The activity results block displays student in separate groups scores
And I should see "95.00/100.00" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 1" in the "Activity results" "block"
And I should see "100.00/100.00" in the "Activity results" "block"
@ -107,7 +106,7 @@ Feature: The activity results block displays student in separate groups scores
And I should see "95.00" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 1" in the "Activity results" "block"
And I should see "100.00" in the "Activity results" "block"
@ -130,7 +129,7 @@ Feature: The activity results block displays student in separate groups scores
And I should see "75%" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 1" in the "Activity results" "block"
And I should see "100%" in the "Activity results" "block"
And I should see "Student 2" in the "Activity results" "block"
@ -154,7 +153,7 @@ Feature: The activity results block displays student in separate groups scores
And I should see "75.00/100.00" in the "Activity results" "block"
And I log out
And I log in as "student3"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 3" in the "Activity results" "block"
And I should see "90.00/100.00" in the "Activity results" "block"
And I should see "Student 4" in the "Activity results" "block"
@ -178,7 +177,7 @@ Feature: The activity results block displays student in separate groups scores
And I should see "75.00" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 1" in the "Activity results" "block"
And I should see "100.00" in the "Activity results" "block"
And I should see "Student 2" in the "Activity results" "block"
@ -200,7 +199,7 @@ Feature: The activity results block displays student in separate groups scores
And I should see "75.00%" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "User S1" in the "Activity results" "block"
And I should see "100.00%" in the "Activity results" "block"
And I should see "User S2" in the "Activity results" "block"
@ -222,7 +221,7 @@ Feature: The activity results block displays student in separate groups scores
And I should see "75.00%" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "User" in the "Activity results" "block"
And I should see "100.00%" in the "Activity results" "block"
And I should see "90.00%" in the "Activity results" "block"

View file

@ -42,14 +42,13 @@ Feature: The activity results block displays student in visible groups scores
| student5 | G3 |
| student6 | G3 |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
| Group mode | Visible groups |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
And I give the grade "100.00" to the user "Student 1" for the grade item "Test assignment"
@ -59,7 +58,7 @@ Feature: The activity results block displays student in visible groups scores
And I give the grade "80.00" to the user "Student 5" for the grade item "Test assignment"
And I give the grade "70.00" to the user "Student 6" for the grade item "Test assignment"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Configure the block on the course page to show 1 high score
Given I add the "Activity results" block
@ -87,7 +86,7 @@ Feature: The activity results block displays student in visible groups scores
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group 1" in the "Activity results" "block"
And I should see "95.00/100.00" in the "Activity results" "block"
@ -103,7 +102,7 @@ Feature: The activity results block displays student in visible groups scores
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group 1" in the "Activity results" "block"
And I should see "95.00" in the "Activity results" "block"
@ -120,7 +119,7 @@ Feature: The activity results block displays student in visible groups scores
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group 1" in the "Activity results" "block"
And I should see "95%" in the "Activity results" "block"
And I should see "Group 2" in the "Activity results" "block"
@ -140,7 +139,7 @@ Feature: The activity results block displays student in visible groups scores
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group 1" in the "Activity results" "block"
And I should see "95.00/100.00" in the "Activity results" "block"
And I should see "Group 2" in the "Activity results" "block"
@ -160,7 +159,7 @@ Feature: The activity results block displays student in visible groups scores
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group 1" in the "Activity results" "block"
And I should see "95.00" in the "Activity results" "block"
And I should see "Group 2" in the "Activity results" "block"
@ -180,7 +179,7 @@ Feature: The activity results block displays student in visible groups scores
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group" in the "Activity results" "block"
And I should see "95.00%" in the "Activity results" "block"
And I should see "85.00%" in the "Activity results" "block"
@ -198,7 +197,7 @@ Feature: The activity results block displays student in visible groups scores
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group" in the "Activity results" "block"
And I should see "95.00%" in the "Activity results" "block"
And I should see "85.00%" in the "Activity results" "block"

View file

@ -25,13 +25,12 @@ Feature: The activity results block displays student low scores
| student4 | C1 | student |
| student5 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
And I give the grade "90.00" to the user "Student 1" for the grade item "Test assignment"
@ -40,7 +39,7 @@ Feature: The activity results block displays student low scores
And I give the grade "60.00" to the user "Student 4" for the grade item "Test assignment"
And I give the grade "50.00" to the user "Student 5" for the grade item "Test assignment"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Configure the block on the course page to show 1 low score
Given I add the "Activity results" block

View file

@ -25,22 +25,21 @@ Feature: The activity results block displays student low scores as scales
| student4 | C1 | student |
| student5 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Scales" in the course gradebook
And I press "Add a new scale"
And I set the following fields to these values:
| Name | My Scale |
| Scale | Disappointing, Not good enough, Average, Good, Very good, Excellent! |
And I press "Save changes"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
| id_grade_modgrade_type | Scale |
| id_grade_modgrade_scale | My Scale |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
And I give the grade "Excellent!" to the user "Student 1" for the grade item "Test assignment"
@ -49,7 +48,7 @@ Feature: The activity results block displays student low scores as scales
And I give the grade "Average" to the user "Student 4" for the grade item "Test assignment"
And I give the grade "Not good enough" to the user "Student 5" for the grade item "Test assignment"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Configure the block on the course page to show 1 low score
Given I add the "Activity results" block

View file

@ -42,15 +42,14 @@ Feature: The activity results block displays students in groups low scores as sc
| student5 | G3 |
| student6 | G3 |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Scales" in the course gradebook
And I press "Add a new scale"
And I set the following fields to these values:
| Name | My Scale |
| Scale | Disappointing, Not good enough, Average, Good, Very good, Excellent! |
And I press "Save changes"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
@ -58,7 +57,7 @@ Feature: The activity results block displays students in groups low scores as sc
| id_grade_modgrade_type | Scale |
| id_grade_modgrade_scale | My Scale |
| Group mode | Separate groups |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
And I give the grade "Excellent!" to the user "Student 1" for the grade item "Test assignment"
@ -68,7 +67,7 @@ Feature: The activity results block displays students in groups low scores as sc
And I give the grade "Good" to the user "Student 5" for the grade item "Test assignment"
And I give the grade "Average" to the user "Student 6" for the grade item "Test assignment"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Try to configure the block on the course page to show 1 low score
Given I add the "Activity results" block
@ -83,7 +82,7 @@ Feature: The activity results block displays students in groups low scores as sc
And I should see "Good" in the "Activity results" "block"
And I log out
And I log in as "student5"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 6" in the "Activity results" "block"
And I should see "Average" in the "Activity results" "block"
@ -102,7 +101,7 @@ Feature: The activity results block displays students in groups low scores as sc
And I should see "Good" in the "Activity results" "block"
And I log out
And I log in as "student3"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 3" in the "Activity results" "block"
And I should see "Very good" in the "Activity results" "block"
And I should see "Student 4" in the "Activity results" "block"
@ -122,7 +121,7 @@ Feature: The activity results block displays students in groups low scores as sc
And I should see "Good" in the "Activity results" "block"
And I log out
And I log in as "student5"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "User S5" in the "Activity results" "block"
And I should see "Good" in the "Activity results" "block"
And I should see "User S6" in the "Activity results" "block"
@ -142,7 +141,7 @@ Feature: The activity results block displays students in groups low scores as sc
And I should see "Good" in the "Activity results" "block"
And I log out
And I log in as "student5"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "User" in the "Activity results" "block"
And I should see "Good" in the "Activity results" "block"
And I should see "Average" in the "Activity results" "block"

View file

@ -42,14 +42,13 @@ Feature: The activity results block displays students in separate groups scores
| student5 | G3 |
| student6 | G3 |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
| Group mode | Separate groups |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
And I give the grade "100.00" to the user "Student 1" for the grade item "Test assignment"
@ -59,7 +58,7 @@ Feature: The activity results block displays students in separate groups scores
And I give the grade "80.00" to the user "Student 5" for the grade item "Test assignment"
And I give the grade "70.00" to the user "Student 6" for the grade item "Test assignment"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Configure the block on the course page to show 1 low score
Given I add the "Activity results" block
@ -89,7 +88,7 @@ Feature: The activity results block displays students in separate groups scores
And I should see "75.00/100.00" in the "Activity results" "block"
And I log out
And I log in as "student5"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 6" in the "Activity results" "block"
And I should see "70.00/100.00" in the "Activity results" "block"
@ -107,7 +106,7 @@ Feature: The activity results block displays students in separate groups scores
And I should see "75.00" in the "Activity results" "block"
And I log out
And I log in as "student5"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 6" in the "Activity results" "block"
And I should see "70.00" in the "Activity results" "block"
@ -128,7 +127,7 @@ Feature: The activity results block displays students in separate groups scores
And I should see "75%" in the "Activity results" "block"
And I log out
And I log in as "student5"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 6" in the "Activity results" "block"
And I should see "70%" in the "Activity results" "block"
And I should see "Student 5" in the "Activity results" "block"
@ -150,7 +149,7 @@ Feature: The activity results block displays students in separate groups scores
And I should see "75.00/100.00" in the "Activity results" "block"
And I log out
And I log in as "student3"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 3" in the "Activity results" "block"
And I should see "90.00/100.00" in the "Activity results" "block"
And I should see "Student 4" in the "Activity results" "block"
@ -172,7 +171,7 @@ Feature: The activity results block displays students in separate groups scores
And I should see "75.00" in the "Activity results" "block"
And I log out
And I log in as "student5"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Student 5" in the "Activity results" "block"
And I should see "80.00" in the "Activity results" "block"
And I should see "Student 6" in the "Activity results" "block"
@ -193,7 +192,7 @@ Feature: The activity results block displays students in separate groups scores
And I should see "75.00%" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "User S1" in the "Activity results" "block"
And I should see "100.00%" in the "Activity results" "block"
And I should see "User S2" in the "Activity results" "block"
@ -214,7 +213,7 @@ Feature: The activity results block displays students in separate groups scores
And I should see "75.00%" in the "Activity results" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "User" in the "Activity results" "block"
And I should see "100.00%" in the "Activity results" "block"
And I should see "90.00%" in the "Activity results" "block"

View file

@ -42,14 +42,13 @@ Feature: The activity results block displays student in visible groups low score
| student5 | G3 |
| student6 | G3 |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment |
| Description | Offline text |
| assignsubmission_file_enabled | 0 |
| Group mode | Visible groups |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "View > Grader report" in the course gradebook
And I turn editing mode on
And I give the grade "100.00" to the user "Student 1" for the grade item "Test assignment"
@ -59,7 +58,7 @@ Feature: The activity results block displays student in visible groups low score
And I give the grade "80.00" to the user "Student 5" for the grade item "Test assignment"
And I give the grade "70.00" to the user "Student 6" for the grade item "Test assignment"
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Scenario: Configure the block on the course page to show 1 low score
Given I add the "Activity results" block
@ -87,7 +86,7 @@ Feature: The activity results block displays student in visible groups low score
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group 3" in the "Activity results" "block"
And I should see "75.00/100.00" in the "Activity results" "block"
@ -103,7 +102,7 @@ Feature: The activity results block displays student in visible groups low score
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group 3" in the "Activity results" "block"
And I should see "75.00" in the "Activity results" "block"
@ -124,7 +123,7 @@ Feature: The activity results block displays student in visible groups low score
And I should see "75%" in the "Activity results" "block"
And I log out
And I log in as "student5"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Group 2" in the "Activity results" "block"
And I should see "85%" in the "Activity results" "block"
And I should see "Group 3" in the "Activity results" "block"
@ -142,7 +141,7 @@ Feature: The activity results block displays student in visible groups low score
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group 2" in the "Activity results" "block"
And I should see "85.00/100.00" in the "Activity results" "block"
And I should see "Group 3" in the "Activity results" "block"
@ -160,7 +159,7 @@ Feature: The activity results block displays student in visible groups low score
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group 2" in the "Activity results" "block"
And I should see "85.00" in the "Activity results" "block"
And I should see "Group 3" in the "Activity results" "block"
@ -178,7 +177,7 @@ Feature: The activity results block displays student in visible groups low score
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group" in the "Activity results" "block"
And I should see "85.00%" in the "Activity results" "block"
And I should see "75.00%" in the "Activity results" "block"
@ -195,7 +194,7 @@ Feature: The activity results block displays student in visible groups low score
And I press "Save changes"
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Group" in the "Activity results" "block"
And I should see "85.00%" in the "Activity results" "block"
And I should see "75.00%" in the "Activity results" "block"

View file

@ -21,14 +21,12 @@ Feature: Enable Block Badges in a course without badges
| enablebadges | 0 |
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Latest badges" block
Then I should see "Badges are not enabled on this site." in the "Latest badges" "block"
Scenario: Add the block to a the course when badges are enabled
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Latest badges" block
Then I should see "You have no badges to display" in the "Latest badges" "block"

View file

@ -15,7 +15,7 @@ Feature: Enable Block Badges in a course
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Issue badge 1 of 2
And I navigate to "Add a new badge" node in "Course administration > Badges"
And I set the following fields to these values:
@ -54,16 +54,14 @@ Feature: Enable Block Badges in a course
Scenario: Add the recent badges block to a course.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Latest badges" block
Then I should see "Badge 1" in the "Latest badges" "block"
And I should see "Badge 2" in the "Latest badges" "block"
Scenario: Add the recent badges block to a course and limit it to only display 1 badge.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Latest badges" block
And I configure the "Latest badges" block
And I set the following fields to these values:

View file

@ -15,7 +15,7 @@ Feature: Enable Block Badges on the dashboard and view awarded badges
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Issue badge 1 of 2
And I navigate to "Add a new badge" node in "Course administration > Badges"
And I set the following fields to these values:

View file

@ -20,7 +20,7 @@ Feature: Enable Block Badges on the frontpage and view awarded badges
And I add the "Latest badges" block
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Issue badge 1 of 2
And I navigate to "Add a new badge" node in "Course administration > Badges"
And I set the following fields to these values:

View file

@ -21,8 +21,7 @@ Feature: Enable Block blog menu in a course
| enableblogs | 0 |
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Blog menu" block
Then I should see "Blogging is disabled!" in the "Blog menu" "block"
@ -32,8 +31,7 @@ Feature: Enable Block blog menu in a course
| useblogassociations | 0 |
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Blog menu" block
Then I should see "Blog entries" in the "Blog menu" "block"
And I should see "Add a new entry" in the "Blog menu" "block"
@ -47,8 +45,7 @@ Feature: Enable Block blog menu in a course
| useblogassociations | 1 |
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Blog menu" block
Then I should see "Blog entries" in the "Blog menu" "block"
And I should see "Add a new entry" in the "Blog menu" "block"
@ -62,8 +59,7 @@ Feature: Enable Block blog menu in a course
| enablerssfeeds | 0 |
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Blog menu" block
Then I should not see "Blog RSS feed" in the "Blog menu" "block"
And I should see "Add a new entry" in the "Blog menu" "block"
@ -74,8 +70,7 @@ Feature: Enable Block blog menu in a course
| enablerssfeeds | 1 |
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Blog menu" block
Then I should see "Blog RSS feed" in the "Blog menu" "block"
And I should see "Add a new entry" in the "Blog menu" "block"

View file

@ -19,8 +19,7 @@ Feature: Enable Block blog menu in an activity
| student1 | C1 | student |
| student2 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment 1 |
| Description | Offline text |
@ -31,7 +30,7 @@ Feature: Enable Block blog menu in an activity
Scenario: Students use the blog menu block to post blogs
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add a new entry"
When I set the following fields to these values:
@ -40,7 +39,7 @@ Feature: Enable Block blog menu in an activity
And I press "Save changes"
Then I should see "S1 First Blog"
And I should see "This is my awesome blog!"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Blog entries"
And I should see "S1 First Blog"
@ -48,7 +47,7 @@ Feature: Enable Block blog menu in an activity
Scenario: Students use the blog menu block to view their blogs about the activity
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add an entry about this Assignment"
And I set the following fields to these values:
@ -60,7 +59,7 @@ Feature: Enable Block blog menu in an activity
And I should see "Associated Assignment: Test assignment 1"
And I log out
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add a new entry"
And I set the following fields to these values:
@ -70,7 +69,7 @@ Feature: Enable Block blog menu in an activity
And I should see "S2 Second Blog"
And I should see "My unrelated blog!"
And I should not see "Associated Assignment: Test assignment 1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add an entry about this Assignment"
And I set the following fields to these values:
@ -80,7 +79,7 @@ Feature: Enable Block blog menu in an activity
And I should see "S2 First Blog"
And I should see "My course blog is better!"
And I should see "Associated Assignment: Test assignment 1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
When I follow "View my entries about this Assignment"
Then I should see "S2 First Blog"
@ -89,7 +88,7 @@ Feature: Enable Block blog menu in an activity
Scenario: Students use the blog menu block to view all blogs about the assignment
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add an entry about this Assignment"
And I set the following fields to these values:
@ -101,7 +100,7 @@ Feature: Enable Block blog menu in an activity
And I should see "Associated Assignment: Test assignment 1"
And I log out
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add a new entry"
And I set the following fields to these values:
@ -111,7 +110,7 @@ Feature: Enable Block blog menu in an activity
And I should see "S2 Second Blog"
And I should see "My unrelated blog!"
And I should not see "Associated Assignment: Test assignment 1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add an entry about this Assignment"
And I set the following fields to these values:
@ -121,7 +120,7 @@ Feature: Enable Block blog menu in an activity
And I should see "S2 First Blog"
And I should see "My course blog is better!"
And I should see "Associated Assignment: Test assignment 1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
When I follow "View all entries about this Assignment"
Then I should see "S1 First Blog"
@ -130,7 +129,7 @@ Feature: Enable Block blog menu in an activity
Scenario: Students use the blog menu block to view all their blog entries
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add an entry about this Assignment"
And I set the following fields to these values:
@ -142,7 +141,7 @@ Feature: Enable Block blog menu in an activity
And I should see "Associated Assignment: Test assignment 1"
And I log out
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add a new entry"
And I set the following fields to these values:
@ -152,7 +151,7 @@ Feature: Enable Block blog menu in an activity
And I should see "S2 Second Blog"
And I should see "My unrelated blog!"
And I should not see "Associated Assignment: Test assignment 1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add an entry about this Assignment"
And I set the following fields to these values:
@ -162,7 +161,7 @@ Feature: Enable Block blog menu in an activity
And I should see "S2 First Blog"
And I should see "My course blog is better!"
And I should see "Associated Assignment: Test assignment 1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
When I follow "Blog entries"
Then I should see "S2 First Blog"
@ -171,7 +170,7 @@ Feature: Enable Block blog menu in an activity
Scenario: Teacher searches for student blogs
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add an entry about this Assignment"
And I set the following fields to these values:
@ -183,7 +182,7 @@ Feature: Enable Block blog menu in an activity
And I should see "Associated Assignment: Test assignment 1"
And I log out
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add a new entry"
And I set the following fields to these values:
@ -193,7 +192,7 @@ Feature: Enable Block blog menu in an activity
And I should see "S2 Second Blog"
And I should see "My unrelated blog!"
And I should not see "Associated Assignment: Test assignment 1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add an entry about this Assignment"
And I set the following fields to these values:
@ -205,7 +204,7 @@ Feature: Enable Block blog menu in an activity
And I should see "Associated Assignment: Test assignment 1"
And I log out
When I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I set the field "blogsearchquery" to "First"
And I press "Search"

View file

@ -19,14 +19,13 @@ Feature: Students can use block blog menu in a course
| student1 | C1 | student |
| student2 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Blog menu" block
And I log out
Scenario: Students use the blog menu block to post blogs
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add a new entry"
When I set the following fields to these values:
| Entry title | S1 First Blog |
@ -34,14 +33,14 @@ Feature: Students can use block blog menu in a course
And I press "Save changes"
Then I should see "S1 First Blog"
And I should see "This is my awesome blog!"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Blog entries"
And I should see "S1 First Blog"
And I should see "This is my awesome blog!"
Scenario: Students use the blog menu block to view their blogs about the course
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add an entry about this course"
And I set the following fields to these values:
| Entry title | S1 First Blog |
@ -52,7 +51,7 @@ Feature: Students can use block blog menu in a course
And I should see "Associated Course: C1"
And I log out
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add a new entry"
And I set the following fields to these values:
| Entry title | S2 Second Blog |
@ -61,7 +60,7 @@ Feature: Students can use block blog menu in a course
And I should see "S2 Second Blog"
And I should see "My unrelated blog!"
And I should not see "Associated Course: C1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add an entry about this course"
And I set the following fields to these values:
| Entry title | S2 First Blog |
@ -70,7 +69,7 @@ Feature: Students can use block blog menu in a course
And I should see "S2 First Blog"
And I should see "My course blog is better!"
And I should see "Associated Course: C1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
When I follow "View my entries about this course"
Then I should see "S2 First Blog"
And I should not see "S2 Second Blog"
@ -78,7 +77,7 @@ Feature: Students can use block blog menu in a course
Scenario: Students use the blog menu block to view all blogs about the course
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add an entry about this course"
And I set the following fields to these values:
| Entry title | S1 First Blog |
@ -89,7 +88,7 @@ Feature: Students can use block blog menu in a course
And I should see "Associated Course: C1"
And I log out
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add a new entry"
And I set the following fields to these values:
| Entry title | S2 Second Blog |
@ -98,7 +97,7 @@ Feature: Students can use block blog menu in a course
And I should see "S2 Second Blog"
And I should see "My unrelated blog!"
And I should not see "Associated Course: C1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add an entry about this course"
And I set the following fields to these values:
| Entry title | S2 First Blog |
@ -107,7 +106,7 @@ Feature: Students can use block blog menu in a course
And I should see "S2 First Blog"
And I should see "My course blog is better!"
And I should see "Associated Course: C1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
When I follow "View all entries for this course"
Then I should see "S1 First Blog"
And I should see "S2 First Blog"
@ -115,7 +114,7 @@ Feature: Students can use block blog menu in a course
Scenario: Students use the blog menu block to view all their blog entries
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add an entry about this course"
And I set the following fields to these values:
| Entry title | S1 First Blog |
@ -126,7 +125,7 @@ Feature: Students can use block blog menu in a course
And I should see "Associated Course: C1"
And I log out
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add a new entry"
And I set the following fields to these values:
| Entry title | S2 Second Blog |
@ -135,7 +134,7 @@ Feature: Students can use block blog menu in a course
And I should see "S2 Second Blog"
And I should see "My unrelated blog!"
And I should not see "Associated Course: C1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add an entry about this course"
And I set the following fields to these values:
| Entry title | S2 First Blog |
@ -144,7 +143,7 @@ Feature: Students can use block blog menu in a course
And I should see "S2 First Blog"
And I should see "My course blog is better!"
And I should see "Associated Course: C1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
When I follow "Blog entries"
Then I should see "S2 First Blog"
And I should see "S2 Second Blog"
@ -152,7 +151,7 @@ Feature: Students can use block blog menu in a course
Scenario: Teacher searches for student blogs
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add an entry about this course"
And I set the following fields to these values:
| Entry title | S1 First Blog |
@ -163,7 +162,7 @@ Feature: Students can use block blog menu in a course
And I should see "Associated Course: C1"
And I log out
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add a new entry"
And I set the following fields to these values:
| Entry title | S2 Second Blog |
@ -172,7 +171,7 @@ Feature: Students can use block blog menu in a course
And I should see "S2 Second Blog"
And I should see "My unrelated blog!"
And I should not see "Associated Course: C1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add an entry about this course"
And I set the following fields to these values:
| Entry title | S2 First Blog |
@ -183,7 +182,7 @@ Feature: Students can use block blog menu in a course
And I should see "Associated Course: C1"
And I log out
When I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I set the field "blogsearchquery" to "First"
And I press "Search"
Then I should see "S1 First Blog"

View file

@ -21,14 +21,12 @@ Feature: Feature: Users can use the recent blog entries block to view recent blo
| enableblogs | 0 |
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Recent blog entries" block
Then I should see "Blogging is disabled!" in the "Recent blog entries" "block"
Scenario: Add the recent blogs block to a course when there are not any blog posts
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Recent blog entries" block
Then I should see "No recent entries" in the "Recent blog entries" "block"

View file

@ -19,8 +19,7 @@ Feature: Students can use the recent blog entries block to view recent entries o
| student1 | C1 | student |
| student2 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Test assignment 1 |
| Description | Offline text |
@ -32,7 +31,7 @@ Feature: Students can use the recent blog entries block to view recent entries o
Scenario: Students use the recent blog entries block to view blogs
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add an entry about this Assignment"
When I set the following fields to these values:
@ -48,7 +47,7 @@ Feature: Students can use the recent blog entries block to view recent entries o
Scenario: Students only see a few entries in the recent blog entries block
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test assignment 1"
And I follow "Add an entry about this Assignment"
# Blog 1 of 5
@ -106,8 +105,7 @@ Feature: Students can use the recent blog entries block to view recent entries o
And I should see "This is my awesome blog!"
Then I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I follow "Test assignment 1"
And I configure the "Recent blog entries" block
And I set the following fields to these values:

View file

@ -17,15 +17,14 @@ Feature: Students can use the recent blog entries block to view recent entries o
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Blog menu" block
And I add the "Recent blog entries" block
And I log out
Scenario: Students use the recent blog entries block to view blogs
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add an entry about this course"
When I set the following fields to these values:
| Entry title | S1 First Blog |
@ -40,7 +39,7 @@ Feature: Students can use the recent blog entries block to view recent entries o
Scenario: Students only see a few entries in the recent blog entries block
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Add an entry about this course"
# Blog 1 of 5
And I set the following fields to these values:
@ -97,8 +96,7 @@ Feature: Students can use the recent blog entries block to view recent entries o
And I should see "This is my awesome blog!"
Then I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I configure the "Recent blog entries" block
And I set the following fields to these values:
| id_config_numberofrecentblogentries | 2 |

View file

@ -21,8 +21,7 @@ Feature: Adding blog tag block
| teacher1 | c1 | editingteacher |
| student1 | c1 | student |
When I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Blog tags" block
# TODO MDL-57120 site "Blogs" link not accessible without navigation block.
And I add the "Navigation" block if not present
@ -37,7 +36,7 @@ Feature: Adding blog tag block
And I press "Save changes"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to course participants
And I click on "Course blogs" "link" in the "Navigation" "block"
And I follow "Blog about this Course"

View file

@ -21,8 +21,7 @@ Feature: Enable the calendar block in a course and test it's functionality
Scenario: Add the block to a the course
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Calendar" block
Then I should see "Events key" in the "Calendar" "block"
@ -34,8 +33,7 @@ Feature: Enable the calendar block in a course and test it's functionality
| id_name | Site Event |
And I log out
When I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Calendar" block
And I hover over today in the calendar
Then I should see "Site Event"
@ -48,13 +46,12 @@ Feature: Enable the calendar block in a course and test it's functionality
| id_name | Site Event |
And I log out
When I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Calendar" block
And I create a calendar event with form data:
| id_eventtype | Course |
| id_name | Course Event |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Hide global events"
And I hover over today in the calendar
Then I should not see "Site Event"
@ -63,31 +60,29 @@ Feature: Enable the calendar block in a course and test it's functionality
@javascript
Scenario: View a course event in the calendar block
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Calendar" block
And I create a calendar event with form data:
| id_eventtype | Course |
| id_name | Course Event |
When I am on course page "Course 1"
When I am on "Course 1" course homepage
And I hover over today in the calendar
Then I should see "Course Event"
@javascript
Scenario: Filter course events in the calendar block
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Calendar" block
And I create a calendar event with form data:
| id_eventtype | Course |
| id_name | Course Event |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I create a calendar event with form data:
| id_eventtype | User |
| id_name | User Event |
When I am on homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Hide course events"
And I hover over today in the calendar
Then I should not see "Course Event"
@ -96,32 +91,30 @@ Feature: Enable the calendar block in a course and test it's functionality
@javascript
Scenario: View a user event in the calendar block
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Calendar" block
And I create a calendar event with form data:
| id_eventtype | User |
| id_name | User Event |
When I am on homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I hover over today in the calendar
Then I should see "User Event"
@javascript
Scenario: Filter user events in the calendar block
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Calendar" block
And I create a calendar event with form data:
| id_eventtype | Course |
| id_name | Course Event |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I create a calendar event with form data:
| id_eventtype | User |
| id_name | User Event |
When I am on homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Hide user events"
And I hover over today in the calendar
Then I should not see "User Event"
@ -138,7 +131,7 @@ Feature: Enable the calendar block in a course and test it's functionality
| student1 | G1 |
| student2 | G2 |
When I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" node in "Course administration"
And I set the following fields to these values:
| id_groupmode | Separate groups |
@ -152,12 +145,12 @@ Feature: Enable the calendar block in a course and test it's functionality
| id_name | Group Event |
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I hover over today in the calendar
And I should see "Group Event"
And I log out
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I hover over today in the calendar
And I should not see "Group Event"
@ -172,7 +165,7 @@ Feature: Enable the calendar block in a course and test it's functionality
| student1 | G1 |
| student2 | G2 |
When I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" node in "Course administration"
And I set the following fields to these values:
| id_groupmode | Separate groups |
@ -183,14 +176,14 @@ Feature: Enable the calendar block in a course and test it's functionality
And I create a calendar event with form data:
| id_eventtype | Course |
| id_name | Course Event 1 |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I create a calendar event with form data:
| id_eventtype | Group |
| id_groupid | Group 1 |
| id_name | Group Event 1 |
And I log out
Then I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Hide group events"
And I hover over today in the calendar
And I should not see "Group Event 1"

View file

@ -21,8 +21,7 @@ Feature: Enable the calendar block in a course
| id_name | Site Event |
And I log out
Then I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Calendar" block
And I hover over today in the calendar
And I should see "Site Event"

View file

@ -17,12 +17,11 @@ Feature: Add a comment to the comments block
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Comments" block
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
@javascript
Scenario: Add a comment with Javascript enabled
@ -69,7 +68,7 @@ Feature: Add a comment to the comments block
And I add "Super test comment 31" comment to comments block
Then I should see "Super test comment 01"
And I should see "Super test comment 31"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should not see "Super test comment 01"
And I should not see "Super test comment 02"
And I should not see "Super test comment 16"

View file

@ -20,15 +20,14 @@ Feature: Enable Block comments on an activity page and view comments
| activity | course | idnumber | name | intro |
| page | C1 | page1 | Test page name | Test page description |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I follow "Test page name"
And I add the "Comments" block
And I follow "Show comments"
And I add "I'm a comment from the teacher" comment to comments block
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test page name"
And I follow "Show comments"
Then I should see "I'm a comment from the teacher"

View file

@ -17,13 +17,12 @@ Feature: Enable Block comments on a course page and view comments
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Comments" block
And I follow "Show comments"
And I add "I'm a comment from the teacher" comment to comments block
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Show comments"
Then I should see "I'm a comment from the teacher"

View file

@ -18,16 +18,15 @@ Feature: Delete comment block messages
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Comments" block
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add "Comment from student1" comment to comments block
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add "Comment from teacher1" comment to comments block
When I delete "Comment from student1" comment from comments block
Then I should not see "Comment from student1"

View file

@ -19,8 +19,7 @@ Feature: Enable Block Completion in a course
Scenario: Add the block to a the course where completion is disabled
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I navigate to "Edit settings" node in "Course administration"
And I set the following fields to these values:
| Enable completion tracking | No |
@ -30,8 +29,7 @@ Feature: Enable Block Completion in a course
Scenario: Add the block to a the course where completion is not set
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Course completion status" block
Then I should see "No completion criteria set for this course" in the "Course completion status" "block"
@ -40,8 +38,7 @@ Feature: Enable Block Completion in a course
| activity | course | idnumber | name | intro |
| page | C1 | page1 | Test page name | Test page description |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I follow "Test page name"
And I navigate to "Edit settings" in current page administration
And I set the following fields to these values:

View file

@ -22,8 +22,7 @@ Feature: Enable Block Completion in a course using activity completion
Scenario: Add the block to a the course and add course completion items
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I follow "Test page name"
And I navigate to "Edit settings" in current page administration
And I set the following fields to these values:
@ -38,14 +37,13 @@ Feature: Enable Block Completion in a course using activity completion
And I press "Save changes"
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Status: Not yet started" in the "Course completion status" "block"
And I should see "0 of 1" in the "Activity completion" "table_row"
Scenario: Add the block to a the course and add course completion items
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I follow "Test page name"
And I navigate to "Edit settings" in current page administration
And I set the following fields to these values:
@ -60,13 +58,13 @@ Feature: Enable Block Completion in a course using activity completion
And I press "Save changes"
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "Test page name"
And I follow "C1"
Then I should see "Status: Pending" in the "Course completion status" "block"
And I should see "0 of 1" in the "Activity completion" "table_row"
And I trigger cron
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "1 of 1" in the "Activity completion" "table_row"
And I follow "More details"
And I should see "Yes" in the "Activity completion" "table_row"

View file

@ -21,8 +21,7 @@ Feature: Enable Block Completion in a course using manual completion by others
Scenario: Add the block to a the course and mark a student complete.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Course completion status" block
And I navigate to "Course completion" node in "Course administration"
And I expand all fieldsets
@ -31,12 +30,12 @@ Feature: Enable Block Completion in a course using manual completion by others
And I press "Save changes"
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Status: Not yet started" in the "Course completion status" "block"
And I should see "No" in the "Teacher" "table_row"
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Course completion" node in "Course administration > Reports"
And I follow "Click to mark user complete"
# Running completion task just after clicking sometimes fail, as record
@ -46,7 +45,7 @@ Feature: Enable Block Completion in a course using manual completion by others
And I am on site homepage
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Status: Complete" in the "Course completion status" "block"
And I should see "Yes" in the "Teacher" "table_row"
And I follow "More details"
@ -54,8 +53,7 @@ Feature: Enable Block Completion in a course using manual completion by others
Scenario: Add the block to a the course and require multiple roles to mark a student complete.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Course completion status" block
And I navigate to "Course completion" node in "Course administration"
And I expand all fieldsets
@ -66,18 +64,18 @@ Feature: Enable Block Completion in a course using manual completion by others
And I press "Save changes"
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Status: Not yet started" in the "Course completion status" "block"
And I should see "No" in the "Teacher" "table_row"
And I should see "No" in the "Non-editing teacher" "table_row"
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Course completion" node in "Course administration > Reports"
And I follow "Click to mark user complete"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Status: In progress" in the "Course completion status" "block"
And I should see "Yes" in the "Teacher" "table_row"
And I should see "No" in the "Non-editing teacher" "table_row"
@ -86,7 +84,7 @@ Feature: Enable Block Completion in a course using manual completion by others
And I should see "No" in the "Marked complete by Non-editing teacher" "table_row"
And I log out
And I log in as "teacher2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Course completion" node in "Course administration > Reports"
And I follow "Click to mark user complete"
# Running completion task just after clicking sometimes fail, as record
@ -96,7 +94,7 @@ Feature: Enable Block Completion in a course using manual completion by others
And I am on site homepage
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Status: Complete" in the "Course completion status" "block"
And I should see "Yes" in the "Teacher" "table_row"
And I should see "Yes" in the "Non-editing teacher" "table_row"

View file

@ -17,8 +17,7 @@ Feature: Enable Block Completion in a course using manual self completion
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Course completion status" block
And I add the "Self completion" block
And I navigate to "Course completion" node in "Course administration"
@ -28,7 +27,7 @@ Feature: Enable Block Completion in a course using manual self completion
And I press "Save changes"
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Status: Not yet started" in the "Course completion status" "block"
And I should see "No" in the "Self completion" "table_row"
And I follow "Complete course"
@ -39,7 +38,7 @@ Feature: Enable Block Completion in a course using manual self completion
# should be created before the task runs.
And I wait "1" seconds
And I run the scheduled task "core\task\completion_regular_task"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Status: Complete" in the "Course completion status" "block"
And I should see "Yes" in the "Self completion" "table_row"
And I follow "More details"

View file

@ -58,7 +58,7 @@ Feature: Enable the course_list block on a category page and view it's contents
And I should see "Course 2" in the "My courses" "block"
And I should see "Course 3" in the "My courses" "block"
And I should not see "Course 4" in the "My courses" "block"
And I am on course page "Course 3"
And I am on "Course 3" course homepage
And I should see "Course 3"
Scenario: Add the course list block on category page and view as an admin

View file

@ -27,8 +27,7 @@ Feature: Enable the course_list block on a course page and view it's contents
Scenario: Add the course list block on course page and navigate to the course listing
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Courses" block
Then I should see "Course 1" in the "My courses" "block"
And I should see "Course 2" in the "My courses" "block"
@ -39,21 +38,18 @@ Feature: Enable the course_list block on a course page and view it's contents
Scenario: Add the course list block on course page and navigate to another course
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Courses" block
Then I should see "Course 1" in the "My courses" "block"
And I should see "Course 2" in the "My courses" "block"
And I should see "Course 3" in the "My courses" "block"
And I should not see "Course 4" in the "My courses" "block"
And I am on course page "Course 3"
And I am on "Course 3" course homepage
And I should see "Course 3"
Scenario: Add the course list block on course page and view as an admin
Given I log in as "admin"
And I am on site homepage
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Courses" block
Then I should see "Miscellaneous" in the "Course categories" "block"
And I should see "Category 1" in the "Course categories" "block"
@ -68,8 +64,7 @@ Feature: Enable the course_list block on a course page and view it's contents
Given the following config values are set as admin:
| block_course_list_hideallcourseslink | 1 |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Courses" block
Then I should not see "All courses" in the "My courses" "block"
@ -80,9 +75,7 @@ Feature: Enable the course_list block on a course page and view it's contents
| user | course | role |
| admin | C1 | editingteacher |
And I log in as "admin"
And I am on site homepage
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Courses" block
Then I should not see "Miscellaneous" in the "My courses" "block"
And I should not see "Category 1" in the "My courses" "block"

View file

@ -44,7 +44,7 @@ Feature: Enable the course_list block on the dashboard and view it's contents
And I should see "Course 2" in the "My courses" "block"
And I should see "Course 3" in the "My courses" "block"
And I should not see "Course 4" in the "My courses" "block"
And I am on course page "Course 3"
And I am on "Course 3" course homepage
And I should see "Course 3"
Scenario: Add the course list block on the dashboard and view as an admin

View file

@ -52,7 +52,7 @@ Feature: Enable the course_list block on the frontpage and view it's contents
And I should see "Course 2" in the "My courses" "block"
And I should see "Course 3" in the "My courses" "block"
And I should not see "Course 4" in the "My courses" "block"
And I am on course page "Course 3"
And I am on "Course 3" course homepage
And I should see "Course 3"
Scenario: Add the course list block on the frontpage page and view as an admin

View file

@ -17,21 +17,20 @@ Feature: Course summary block used in a course
| student1 | C101 | student |
| teacher1 | C101 | editingteacher |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Course/site summary" block
And I log out
Scenario: Student can view course summary
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then "Course summary" "block" should exist
And I should see "Course summary" in the "Course summary" "block"
And I should see "Proved the course summary block works!" in the "Course summary" "block"
Scenario: Teacher can not see edit icon when edit mode is off
When I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Proved the course summary block works!" in the "Course summary" "block"
And I should see "Course summary" in the "Course summary" "block"
And "Edit" "link" should not exist in the "Course summary" "block"

View file

@ -19,13 +19,12 @@ Feature: Random glossary entry block is used in a course
Scenario: Student can not see the block if it is not configured
When I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Random glossary entry" block
Then I should see "Please configure this block using the edit icon" in the "block_glossary_random" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And "block_glossary_random" "block" should not exist
And I log out
@ -34,8 +33,7 @@ Feature: Random glossary entry block is used in a course
| activity | name | intro | course | idnumber | defaultapproval |
| glossary | GlossaryAuto | Test glossary description | C1 | glossary1 | 1 |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Random glossary entry" block
And I configure the "block_glossary_random" block
And I set the following fields to these values:
@ -45,14 +43,14 @@ Feature: Random glossary entry block is used in a course
And I press "Save changes"
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "There are no entries yet in the chosen glossary" in the "AutoGlossaryblock" "block"
And I click on "Add a new entry" "link" in the "AutoGlossaryblock" "block"
And I set the following fields to these values:
| Concept | Concept1 |
| Definition | Definition1 |
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Concept1" in the "AutoGlossaryblock" "block"
And I should see "Definition1" in the "AutoGlossaryblock" "block"
And I should not see "There are no entries yet in the chosen glossary" in the "AutoGlossaryblock" "block"
@ -61,7 +59,7 @@ Feature: Random glossary entry block is used in a course
| Concept | Concept2 |
| Definition | Definition2 |
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# Only the last entry appears in the block
And I should not see "Concept1" in the "AutoGlossaryblock" "block"
And I should not see "Definition1" in the "AutoGlossaryblock" "block"
@ -78,8 +76,7 @@ Feature: Random glossary entry block is used in a course
| activity | name | intro | course | idnumber | defaultapproval |
| glossary | GlossaryManual | Test glossary description | C1 | glossary2 | 0 |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Random glossary entry" block
And I configure the "block_glossary_random" block
And I set the following fields to these values:
@ -89,18 +86,18 @@ Feature: Random glossary entry block is used in a course
And I press "Save changes"
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "There are no entries yet in the chosen glossary" in the "ManualGlossaryblock" "block"
And I click on "Add a new entry" "link" in the "ManualGlossaryblock" "block"
And I set the following fields to these values:
| Concept | Concept1 |
| Definition | Definition1 |
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "There are no entries yet in the chosen glossary" in the "ManualGlossaryblock" "block"
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "There are no entries yet in the chosen glossary" in the "ManualGlossaryblock" "block"
And I follow "GlossaryManual"
And I follow "Waiting approval"

View file

@ -23,7 +23,7 @@ Feature: Random glossary entry block linking to global glossary
Scenario: View random (last) entry in the global glossary
When I log in as "admin"
And I am on course page "Course 2"
And I am on "Course 2" course homepage
And I follow "Tips and Tricks"
And I press "Add a new entry"
And I set the following fields to these values:
@ -33,8 +33,7 @@ Feature: Random glossary entry block linking to global glossary
And I log out
# As a teacher add a block to the course page linking to the global glossary.
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Random glossary entry" block
And I configure the "block_glossary_random" block
And I set the following fields to these values:
@ -48,7 +47,7 @@ Feature: Random glossary entry block linking to global glossary
And I log out
# Student who can't see the module is still able to view entries in this block (because the glossary was marked as global)
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Never come late" in the "Tip of the day" "block"
And I should not see "Add a new entry" in the "Tip of the day" "block"
And I should see "View all entries" in the "Tip of the day" "block"
@ -56,8 +55,7 @@ Feature: Random glossary entry block linking to global glossary
Scenario: Removing the global glossary that is used in random glossary block
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Random glossary entry" block
And I configure the "block_glossary_random" block
And I set the following fields to these values:
@ -67,15 +65,15 @@ Feature: Random glossary entry block linking to global glossary
And I press "Save changes"
And I log out
And I log in as "admin"
And I am on course page "Course 2"
And I am on "Course 2" course homepage
And I follow "Tips and Tricks"
And I follow "Edit settings"
And I set the field "globalglossary" to "0"
And I press "Save and return to course"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Please configure this block using the edit icon." in the "Tip of the day" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And "Tip of the day" "block" should not exist
And I log out

View file

@ -17,8 +17,7 @@ Feature: HTML blocks in a course
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
When I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "HTML" block
And I configure the "(new HTML block)" block
And I set the field "Content" to "First block content"
@ -31,6 +30,6 @@ Feature: HTML blocks in a course
And I press "Save changes"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "First block content" in the "First block header" "block"
And I should see "Second block content" in the "Second block header" "block"

View file

@ -21,15 +21,13 @@ Feature: The messages block allows users to list new messages an a course
Given the following config values are set as admin:
| messaging | 0 |
And I log in as "teacher1"
And I am on course page "Course 1"
When I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Messages" block
Then I should see "Messaging is disabled on this site" in the "Messages" "block"
Scenario: View the block by a user who does not have any messages.
Given I log in as "teacher1"
And I am on course page "Course 1"
When I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Messages" block
Then I should see "No messages" in the "Messages" "block"
@ -41,20 +39,18 @@ Feature: The messages block allows users to list new messages an a course
And I send "This is message 2" message to "Teacher 1" user
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
When I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Messages" block
Then I should see "Student 1" in the "Messages" "block"
@javascript
Scenario: Use the block to send a message to a user.
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Messages" block
And I click on "//a[normalize-space(.) = 'Messages']" "xpath_element" in the "Messages" "block"
And I send "This is message 1" message to "Student 1" user
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Teacher 1" in the "Messages" "block"

View file

@ -18,8 +18,7 @@ Feature: The logged in user block allows users to view their profile information
| activity | course | idnumber | name | intro |
| page | C1 | page1 | Test page name | Test page description |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I follow "Test page name"
When I add the "Logged in user" block
Then I should see "Teacher One" in the "Logged in user" "block"

View file

@ -15,7 +15,6 @@ Feature: The logged in user block allows users to view their profile information
| user | course | role |
| teacher1 | C1 | editingteacher |
When I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Logged in user" block
Then I should see "Teacher One" in the "Logged in user" "block"

View file

@ -45,7 +45,7 @@ Feature: Expand the courses nodes within the navigation block
| Page contexts | Display throughout the entire site |
And I press "Save changes"
And I turn editing mode off
And I am on course page "Course 2"
And I am on "Course 2" course homepage
And I navigate to "Enrolment methods" node in "Course administration > Users"
And I click on "Edit" "link" in the "Guest access" "table_row"
And I set the following fields to these values:

View file

@ -17,8 +17,7 @@ Feature: Latest announcements block displays the course latest news
And I enrol "Teacher 1" user as "Teacher"
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Latest announcements" block
And I turn editing mode off
When I add a new topic to "Announcements" forum with:
@ -30,7 +29,7 @@ Feature: Latest announcements block displays the course latest news
And I add a new topic to "Announcements" forum with:
| Subject | Discussion Three |
| Message | Not important |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Discussion One" in the "Latest announcements" "block"
And I should see "Discussion Two" in the "Latest announcements" "block"
And I should see "Discussion Three" in the "Latest announcements" "block"

View file

@ -21,21 +21,19 @@ Feature: The online users block allow you to see who is currently online
Scenario: Add the online users on course page and see myself
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Online users" block
Then I should see "Teacher 1" in the "Online users" "block"
Scenario: Add the online users on course page and see other logged in users
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Online users" block
And I log out
And I log in as "student2"
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Teacher 1" in the "Online users" "block"
And I should see "Student 1" in the "Online users" "block"
And I should not see "Student 2" in the "Online users" "block"

View file

@ -15,20 +15,19 @@ Feature: People Block used in a course
| user | course | role |
| student1 | C101 | student |
And I log in as "admin"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "People" block
And I log out
Scenario: Student can view participants link
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then "People" "block" should exist
And I should see "Participants" in the "People" "block"
Scenario: Student can follow participants link and be directed to the correct page
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I click on "Participants" "link" in the "People" "block"
Then I should see "All participants" in the "#page-content" "css_element"
And the "My courses" select box should contain "C101"
@ -38,5 +37,5 @@ Feature: People Block used in a course
| capability | permission | role | contextlevel | reference |
| moodle/course:viewparticipants | Prevent | student | Course | C101 |
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then "People" "block" should not exist

View file

@ -18,8 +18,7 @@ Feature: The private files block allows users to store files privately in moodle
| activity | course | idnumber | name | intro |
| page | C1 | page1 | Test page name | Test page description |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I follow "Test page name"
And I add the "Private files" block
And I should see "No files available" in the "Private files" "block"

View file

@ -15,8 +15,7 @@ Feature: The private files block allows users to store files privately in moodle
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Private files" block
And I should see "No files available" in the "Private files" "block"
When I follow "Manage private files..."

View file

@ -47,8 +47,7 @@ Feature: View structural changes in recent activity block
Scenario: Check that Added module information is displayed respecting view capability
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Recent activity" block
When I add a "Forum" to section "1" and I fill the form with:
| name | ForumVisibleGroups |
@ -100,7 +99,7 @@ Feature: View structural changes in recent activity block
And I should see "ForumSeparateGroupsG2" in the "Recent activity" "block"
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "ForumVisibleGroups" in the "Recent activity" "block"
And I should see "ForumSeparateGroups" in the "Recent activity" "block"
And I should see "ForumNoGroups" in the "Recent activity" "block"
@ -111,7 +110,7 @@ Feature: View structural changes in recent activity block
And I should not see "ForumSeparateGroupsG2" in the "Recent activity" "block"
And I log out
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "ForumVisibleGroups" in the "Recent activity" "block"
And I should see "ForumSeparateGroups" in the "Recent activity" "block"
And I should see "ForumNoGroups" in the "Recent activity" "block"
@ -122,7 +121,7 @@ Feature: View structural changes in recent activity block
And I should see "ForumSeparateGroupsG2" in the "Recent activity" "block"
And I log out
And I log in as "student3"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "ForumVisibleGroups" in the "Recent activity" "block"
And I should see "ForumSeparateGroups" in the "Recent activity" "block"
And I should see "ForumNoGroups" in the "Recent activity" "block"
@ -134,7 +133,7 @@ Feature: View structural changes in recent activity block
And I log out
# Teachers have capability to see all groups and hidden activities
And I log in as "assistant1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "ForumHidden" in the "Recent activity" "block"
And I should see "ForumVisibleGroupsG1" in the "Recent activity" "block"
And I should see "ForumSeparateGroupsG1" in the "Recent activity" "block"
@ -144,8 +143,7 @@ Feature: View structural changes in recent activity block
Scenario: Updates and deletes in recent activity block
When I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Recent activity" block
And I add a "Forum" to section "1" and I fill the form with:
| name | ForumNew |
@ -155,7 +153,7 @@ Feature: View structural changes in recent activity block
And I log out
And I wait "1" seconds
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Added Forum" in the "Recent activity" "block"
And I should see "ForumNew" in the "Recent activity" "block"
And I log out
@ -163,7 +161,7 @@ Feature: View structural changes in recent activity block
And I wait "1" seconds
# Update forum as a teacher
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "ForumNew"
And I navigate to "Edit settings" in current page administration
And I set the following fields to these values:
@ -173,7 +171,7 @@ Feature: View structural changes in recent activity block
And I wait "1" seconds
# Student 1 already saw that forum was created, now he can see that forum was updated
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should not see "Added Forum" in the "Recent activity" "block"
And I should not see "ForumNew" in the "Recent activity" "block"
And I should see "Updated Forum" in the "Recent activity" "block"
@ -182,7 +180,7 @@ Feature: View structural changes in recent activity block
And I wait "1" seconds
# Student 2 has bigger interval and he can see one entry that forum was created but with the new name
And I log in as "student2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Added Forum" in the "Recent activity" "block"
And I should not see "ForumNew" in the "Recent activity" "block"
And I should not see "Updated Forum" in the "Recent activity" "block"
@ -191,15 +189,14 @@ Feature: View structural changes in recent activity block
And I wait "1" seconds
# Delete forum as a teacher
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I delete "ForumUpdated" activity
And I run all adhoc tasks
And I log out
And I wait "1" seconds
# Students 1 and 2 see that forum was deleted
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should not see "Added Forum" in the "Recent activity" "block"
And I should not see "ForumNew" in the "Recent activity" "block"
And I should not see "Updated Forum" in the "Recent activity" "block"
@ -209,7 +206,7 @@ Feature: View structural changes in recent activity block
And I wait "1" seconds
# Student 3 never knew that forum was created, so he does not see anything
And I log in as "student3"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should not see "Added Forum" in the "Recent activity" "block"
And I should not see "ForumNew" in the "Recent activity" "block"
And I should not see "Updated Forum" in the "Recent activity" "block"

View file

@ -17,7 +17,7 @@ Feature: The search forums block allows users to search for forum posts on cours
| teacher1 | C1 | editingteacher |
| student1 | C1 | student |
And I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Edit settings" node in "Course administration"
And I set the field "id_newsitems" to "1"
And I press "Save and display"
@ -28,7 +28,7 @@ Feature: The search forums block allows users to search for forum posts on cours
Scenario: Use the search forum block in a course without any forum posts
Given I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
When I set the following fields to these values:
| searchform_search | Moodle |
And I press "Go"
@ -36,12 +36,11 @@ Feature: The search forums block allows users to search for forum posts on cours
Scenario: Use the search forum block in a course with a hidden forum and search for posts
Given I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a new topic to "Announcements" forum with:
| Subject | My subject |
| Message | My message |
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I follow "Announcements"
And I navigate to "Edit settings" in current page administration
And I expand all fieldsets
@ -49,7 +48,7 @@ Feature: The search forums block allows users to search for forum posts on cours
And I press "Save and return to course"
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And "Search forums" "block" should exist
And I set the following fields to these values:
| searchform_search | message |
@ -58,13 +57,13 @@ Feature: The search forums block allows users to search for forum posts on cours
Scenario: Use the search forum block in a course and search for posts
Given I log in as "teacher1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a new topic to "Announcements" forum with:
| Subject | My subject |
| Message | My message |
And I log out
When I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And "Search forums" "block" should exist
And I set the following fields to these values:
| searchform_search | message |

View file

@ -15,8 +15,7 @@ Feature: The section links block allows users to quickly navigate around a moodl
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add a "Assignment" to section "5" and I fill the form with:
| Assignment name | Test assignment 1 |
| Description | Offline text |

View file

@ -20,8 +20,7 @@ Feature: Edit activities in social activities block
@javascript
Scenario: Edit name of acitivity in-place in social activities block
Given I log in as "user1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I set the field "Add an activity to section 'section 0'" to "Forum"
And I set the field "Forum name" to "My forum name"
And I press "Save and return to course"
@ -41,8 +40,7 @@ Feature: Edit activities in social activities block
| allowstealth | 1 |
And I log out
And I log in as "user1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Recent activity" block
And I set the field "Add an activity to section 'section 0'" to "Forum"
And I set the field "Forum name" to "My forum name"
@ -81,7 +79,7 @@ Feature: Edit activities in social activities block
And I log out
# Student will not see the module on the course page but can access it from other reports and blocks:
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should not see "My forum name" in the "Social activities" "block"
And I click on "My forum name" "link" in the "Recent activity" "block"
And I should see "My forum name" in the ".breadcrumb" "css_element"

View file

@ -35,12 +35,11 @@ Feature: Block tags displaying tag cloud
Scenario: Add Tags block in a course
When I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Tags" block
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
Then I should see "Dogs" in the "Tags" "block"
And I should see "Cats" in the "Tags" "block"
And I should not see "Neverusedtag" in the "Tags" "block"

View file

@ -17,8 +17,7 @@ Feature: Add blocks
| student1 | C1 | student |
| student2 | C1 | student |
And I log in as "admin"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Blog menu" block
Then I should see "View my entries about this course"

View file

@ -36,7 +36,7 @@ Feature: Add and configure blocks throughout the site
And I set the following fields to these values:
| Page contexts | Display throughout the entire site |
And I press "Save changes"
When I am on course page "Course 1"
When I am on "Course 1" course homepage
Then I should see "Comments" in the "Comments" "block"
And I should see "Save comment" in the "Comments" "block"
And I am on site homepage
@ -44,7 +44,7 @@ Feature: Add and configure blocks throughout the site
And I set the following fields to these values:
| Default weight | -10 (first) |
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
# The first block matching the pattern should be top-left block
And I should see "Comments" in the "//*[@id='region-pre' or @id='block-region-side-pre']/descendant::*[contains(concat(' ', normalize-space(@class), ' '), ' block ')]" "xpath_element"
@ -55,8 +55,7 @@ Feature: Add and configure blocks throughout the site
Scenario: Blocks on courses can have roles assigned to them
Given I log in as "teacher1"
And I am on course page "Course 1"
And I follow "Turn editing on"
And I am on "Course 1" course homepage with editing mode on
And I add the "Search forums" block
Then I should see "Assign roles in Search forums block"
@ -71,4 +70,4 @@ Feature: Add and configure blocks throughout the site
| Block title | Foo " onload="document.getElementsByTagName('body')[0].remove()" alt=" |
| Content | Example |
When I press "Save changes"
Then I should see "Course overview"
Then I should see "My overview"

View file

@ -12,8 +12,7 @@ Feature: Show hidden blocks in a docked block region when editing
| user | course | role |
| admin | C1 | editingteacher |
And I log in as "admin"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Search forums" block
And I add the "Latest announcements" block
And I add the "Upcoming events" block

View file

@ -9,8 +9,7 @@ Feature: Block visibility
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And I log in as "admin"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
@javascript
Scenario: Hiding all blocks on the page should remove the column they're in

View file

@ -15,9 +15,7 @@ Feature: Block appearances
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "admin"
And I am on site homepage
And I am on course page "Course 1"
And I follow "Turn editing on"
And I am on "Course 1" course homepage with editing mode on
And I add a "Survey" to section "1" and I fill the form with:
| Name | Test survey name |
| Survey type | ATTLS (20 item version) |
@ -32,8 +30,7 @@ Feature: Block appearances
And I press "Save changes"
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I follow "Turn editing on"
And I am on "Course 1" course homepage with editing mode on
And I add the "Comments" block
And I configure the "Comments" block
And I set the following fields to these values:
@ -43,7 +40,7 @@ Feature: Block appearances
Scenario: Block settings can be modified so that a block apprears on any page
When I follow "Test survey name"
Then I should see "Comments" in the "Comments" "block"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I configure the "Comments" block
And I set the following fields to these values:
| Display on page types | Any course page |

View file

@ -15,9 +15,7 @@ Feature: Block region moving
| user | course | role |
| teacher1 | C1 | editingteacher |
And I log in as "admin"
And I am on site homepage
And I am on course page "Course 1"
And I follow "Turn editing on"
And I am on "Course 1" course homepage with editing mode on
And I add a "Survey" to section "1" and I fill the form with:
| Name | Test survey name |
| Survey type | ATTLS (20 item version) |
@ -32,8 +30,7 @@ Feature: Block region moving
And I press "Save changes"
And I log out
And I log in as "teacher1"
And I am on course page "Course 1"
And I follow "Turn editing on"
And I am on "Course 1" course homepage with editing mode on
And I add the "Comments" block
And I configure the "Comments" block
And I set the following fields to these values:

View file

@ -17,8 +17,7 @@ Feature: Allowed blocks controls
Scenario: Blocks can be added with the default permissions
Given I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
When I add the "Course completion status" block
And I add the "Activities" block
Then I should see "Activities" in the "Activities" "block"
@ -28,13 +27,12 @@ Feature: Allowed blocks controls
Given I log in as "admin"
And I set the following system permissions of "Teacher" role:
| block/activity_modules:addinstance | Prohibit |
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Users > Permissions" in current page administration
And I override the system permissions of "Teacher" role with:
| block/completionstatus:addinstance | Prohibit |
And I log out
When I log in as "teacher1"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
Then the add block selector should not contain "Activities" block
And the add block selector should not contain "Course completion status" block

View file

@ -9,8 +9,7 @@ Feature: The context of a block can always be returned to it's original state.
| fullname | shortname | category |
| Course 1 | C1 | 0 |
And I log in as "admin"
When I am on course page "Course 1"
And I follow "Turn editing on"
When I am on "Course 1" course homepage with editing mode on
And I add the "Tags" block
Then I should see "Tags" in the "Tags" "block"
And I navigate to course participants
@ -18,7 +17,7 @@ Feature: The context of a block can always be returned to it's original state.
And I set the following fields to these values:
| Display on page types | Any page |
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Assignment1 |
| Description | Description |
@ -28,11 +27,11 @@ Feature: The context of a block can always be returned to it's original state.
| Display on page types | Any assignment module page |
And I press "Save changes"
And I should see "Tags" in the "Tags" "block"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And "Tags" "block" should not exist
And I navigate to course participants
And "Tags" "block" should not exist
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add a "Assignment" to section "1" and I fill the form with:
| Assignment name | Assignment2 |
| Description | Description |
@ -42,7 +41,7 @@ Feature: The context of a block can always be returned to it's original state.
And I set the following fields to these values:
| Display on page types | Any page |
And I press "Save changes"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Tags" in the "Tags" "block"
And I navigate to course participants
And I should see "Tags" in the "Tags" "block"

View file

@ -26,7 +26,7 @@ Feature: Blogs can be set to be only visible by the author.
Scenario: A student can not see another student's blog entries.
Given I log in as "testuser"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to course participants
And I follow "Test2 User2"
And I should see "Miscellaneous"

View file

@ -24,8 +24,7 @@ Feature: Perform basic calendar functionality
| user | group |
| student1 | G1 |
When I log in as "admin"
And I am on course page "Course 1"
And I turn editing mode on
And I am on "Course 1" course homepage with editing mode on
And I add the "Calendar" block
Scenario: Create a site event
@ -35,7 +34,7 @@ Feature: Perform basic calendar functionality
| Description | Come join this awesome event, sucka! |
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "This month"
And I should see "Really awesome event!"
And I log out
@ -50,7 +49,7 @@ Feature: Perform basic calendar functionality
| Description | Come join this awesome event, sucka! |
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "This month"
And I should see "Really awesome event!"
And I log out
@ -66,7 +65,7 @@ Feature: Perform basic calendar functionality
| Description | Come join this awesome event |
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "This month"
And I follow "Really awesome event!"
And "Group 1" "text" should exist in the ".eventlist" "css_element"
@ -82,7 +81,7 @@ Feature: Perform basic calendar functionality
| Description | Come join this awesome event, sucka! |
And I log out
And I log in as "student1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I follow "This month"
And I should not see "Really awesome event!"

View file

@ -17,8 +17,7 @@ Feature: Limit displayed upcoming events
And I log in as "teacher1"
Scenario: I view calendar details for a future event
Given I follow "C1"
And I turn editing mode on
Given I am on "Course 1" course homepage with editing mode on
And I add the "Calendar" block
And I add the "Upcoming events" block
And I follow "This month"
@ -36,6 +35,5 @@ Feature: Limit displayed upcoming events
| Upcoming events look-ahead | 3 months |
And I press "Save changes"
And I wait to be redirected
And I am on site homepage
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I should see "Two months away event"

View file

@ -46,7 +46,7 @@ Feature: Access visible and hidden cohorts
Scenario: Teacher can see visible cohorts defined in the above contexts
When I log in as "teacher"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Enrolment methods" node in "Course administration > Users"
And I select "Cohort sync" from the "Add method" singleselect
Then the "Cohort" select box should contain "Cohort in category 1"
@ -58,10 +58,10 @@ Feature: Access visible and hidden cohorts
And the "Cohort" select box should contain "System empty cohort"
And I set the field "Cohort" to "System cohort"
And I press "Add method"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Enrolled users" node in "Course administration > Users"
And I should see "student@example.com"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Groups" node in "Course administration > Users"
And I press "Auto-create groups"
And the "Select members from cohort" select box should contain "Cohort in category 1"
@ -74,7 +74,7 @@ Feature: Access visible and hidden cohorts
Scenario: System manager can see all cohorts defined in the above contexts
When I log in as "user1"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Enrolment methods" node in "Course administration > Users"
And I select "Cohort sync" from the "Add method" singleselect
Then the "Cohort" select box should contain "Cohort in category 1"
@ -100,7 +100,7 @@ Feature: Access visible and hidden cohorts
Scenario: Category manager can see all cohorts defined in his category and visible cohorts defined above
When I log in as "user2"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Enrolment methods" node in "Course administration > Users"
And I select "Cohort sync" from the "Add method" singleselect
Then the "Cohort" select box should contain "Cohort in category 1"

View file

@ -15,10 +15,10 @@ Feature: Upload users to a cohort
| Course 1 | C1 | 0 |
| Course 2 | C2 | 0 |
And I log in as "admin"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I add "Cohort sync" enrolment method with:
| Cohort | Cohort 1 |
And I am on course page "Course 2"
And I am on "Course 2" course homepage
And I add "Cohort sync" enrolment method with:
| Cohort | Cohort 2 |
When I navigate to "Upload users" node in "Site administration > Users > Accounts"
@ -34,12 +34,12 @@ Feature: Upload users to a cohort
And I click on "Assign" "link" in the "Cohort 2" "table_row"
And the "Current users" select box should contain "Mary Smith (marysmith@example.com)"
And the "Current users" select box should contain "Alice Smith (alicesmith@example.com)"
And I am on course page "Course 1"
And I am on "Course 1" course homepage
And I navigate to "Users > Enrolled users" in current page administration
And I should see "Tom Jones"
And I should see "Bob Jones"
And I should not see "Mary Smith"
And I am on course page "Course 2"
And I am on "Course 2" course homepage
And I navigate to "Users > Enrolled users" in current page administration
And I should see "Mary Smith"
And I should see "Alice Smith"

Some files were not shown because too many files have changed in this diff Show more