mirror of
https://github.com/moodle/moodle.git
synced 2025-08-06 01:16:44 +02:00
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:
parent
3353cfd8c1
commit
fdeeaff954
458 changed files with 1697 additions and 2148 deletions
|
@ -25,7 +25,7 @@ Feature: Workshop submission removal
|
|||
| workshop | TestWorkshop | Test workshop description | c1 | workshop1 |
|
||||
# Teacher sets up assessment form and changes the phase to submission.
|
||||
And I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I edit assessment form in workshop "TestWorkshop" as:"
|
||||
| id_description__idx_0_editor | Aspect1 |
|
||||
| id_description__idx_1_editor | Aspect2 |
|
||||
|
@ -34,7 +34,7 @@ Feature: Workshop submission removal
|
|||
And I log out
|
||||
# Student1 submits.
|
||||
And I log in as "student1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And I add a submission in workshop "TestWorkshop" as:"
|
||||
| Title | Submission1 |
|
||||
|
@ -42,14 +42,14 @@ Feature: Workshop submission removal
|
|||
And I log out
|
||||
# Student2 submits.
|
||||
And I log in as "student2"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I add a submission in workshop "TestWorkshop" as:"
|
||||
| Title | Submission2 |
|
||||
| Submission content | Some content |
|
||||
And I log out
|
||||
# Teacher allocates student3 to be reviewer of student2's submission.
|
||||
And I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And I allocate submissions in workshop "TestWorkshop" as:"
|
||||
| Participant | Reviewer |
|
||||
|
@ -58,7 +58,7 @@ Feature: Workshop submission removal
|
|||
|
||||
Scenario: Students can delete their submissions as long as the submissions are editable and not allocated for assessments
|
||||
Given I log in as "student1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
When I follow "Submission1"
|
||||
Then I should see "Submission1"
|
||||
|
@ -71,12 +71,12 @@ Feature: Workshop submission removal
|
|||
|
||||
Scenario: Students cannot delete their submissions if the submissions are not editable
|
||||
Given I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And I change phase in workshop "TestWorkshop" to "Closed"
|
||||
And I log out
|
||||
And I log in as "student1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
When I follow "Submission1"
|
||||
Then I should see "Submission1"
|
||||
|
@ -84,7 +84,7 @@ Feature: Workshop submission removal
|
|||
|
||||
Scenario: Students cannot delete their submissions if the submissions are allocated for assessments
|
||||
Given I log in as "student2"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
When I follow "Submission2"
|
||||
Then I should see "Submission2"
|
||||
|
@ -92,7 +92,7 @@ Feature: Workshop submission removal
|
|||
|
||||
Scenario: Teachers can delete submissions even if the submissions are allocated for assessments.
|
||||
Given I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And "Submission1" "link" should exist
|
||||
And "Submission2" "link" should exist
|
||||
|
|
|
@ -19,9 +19,7 @@ Feature: Teachers can embed images into instructions and conclusion fields
|
|||
And I follow "Manage private files"
|
||||
And I upload "mod/workshop/tests/fixtures/moodlelogo.png" file to "Files" filemanager
|
||||
And I click on "Save changes" "button"
|
||||
And I am on 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
|
||||
# Create and edit the workshop.
|
||||
When I add a "Workshop" to section "1" and I fill the form with:
|
||||
| Workshop name | Workshop with embedded images |
|
||||
|
|
|
@ -21,7 +21,7 @@ Feature: Provide example submission
|
|||
| workshop | TestWorkshop | Test workshop description | c1 | workshop1 | 1 |
|
||||
# As a teacher, define the assessment form to be used in the workshop.
|
||||
When I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I edit assessment form in workshop "TestWorkshop" as:"
|
||||
| id_description__idx_0_editor | Aspect1 |
|
||||
| id_description__idx_1_editor | Aspect2 |
|
||||
|
|
|
@ -31,7 +31,7 @@ Feature: Exporting workshop submissions and assessments to a portfolio
|
|||
And I log out
|
||||
# Teacher sets up assessment form and changes the phase to submission.
|
||||
And I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I edit assessment form in workshop "TestWorkshop" as:"
|
||||
| id_description__idx_0_editor | Aspect1 |
|
||||
| id_description__idx_1_editor | Aspect2 |
|
||||
|
@ -39,7 +39,7 @@ Feature: Exporting workshop submissions and assessments to a portfolio
|
|||
And I log out
|
||||
# Student1 submits.
|
||||
And I log in as "student1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And I add a submission in workshop "TestWorkshop" as:"
|
||||
| Title | Submission1 |
|
||||
|
@ -47,14 +47,14 @@ Feature: Exporting workshop submissions and assessments to a portfolio
|
|||
And I log out
|
||||
# Student2 submits.
|
||||
And I log in as "student2"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I add a submission in workshop "TestWorkshop" as:"
|
||||
| Title | Submission2 |
|
||||
| Submission content | Some content |
|
||||
And I log out
|
||||
# Teacher allocates reviewers and changes the phase to assessment.
|
||||
And I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And I should see "to allocate: 2"
|
||||
And I should see "Workshop submissions report"
|
||||
|
@ -72,7 +72,7 @@ Feature: Exporting workshop submissions and assessments to a portfolio
|
|||
|
||||
Scenario: Students can export their own submission to a portfolio.
|
||||
Given I log in as "student1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
When I follow "Submission1"
|
||||
Then I should see "Submission1"
|
||||
|
@ -87,7 +87,7 @@ Feature: Exporting workshop submissions and assessments to a portfolio
|
|||
|
||||
Scenario: Students can export submission they have peer-assessed.
|
||||
Given I log in as "student1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And I should see "Submission2"
|
||||
And I follow "Submission2"
|
||||
|
@ -104,7 +104,7 @@ Feature: Exporting workshop submissions and assessments to a portfolio
|
|||
Given the following config values are set as admin:
|
||||
| enableportfolios | 0 |
|
||||
When I log in as "student1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And I follow "Submission1"
|
||||
Then I should see "Submission1"
|
||||
|
|
|
@ -17,8 +17,7 @@ Feature: Setting grades to pass via workshop editing form
|
|||
|
||||
Scenario: Adding a new workshop with grade to pass field set
|
||||
Given I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I turn editing mode on
|
||||
And I am on "Course1" course homepage with editing mode on
|
||||
When I add a "Workshop" to section "1" and I fill the form with:
|
||||
| Workshop name | Awesome workshop |
|
||||
| Description | Grades to pass are set here |
|
||||
|
@ -32,8 +31,7 @@ Feature: Setting grades to pass via workshop editing form
|
|||
|
||||
Scenario: Adding a new workshop with grade to pass fields left empty
|
||||
Given I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I turn editing mode on
|
||||
And I am on "Course1" course homepage with editing mode on
|
||||
When I add a "Workshop" to section "1" and I fill the form with:
|
||||
| Workshop name | Another awesome workshop |
|
||||
| Description | No grades to pass are set here |
|
||||
|
@ -47,8 +45,7 @@ Feature: Setting grades to pass via workshop editing form
|
|||
|
||||
Scenario: Adding a new workshop with non-numeric value of a grade to pass
|
||||
Given I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I turn editing mode on
|
||||
And I am on "Course1" course homepage with editing mode on
|
||||
When I add a "Workshop" to section "1" and I fill the form with:
|
||||
| Workshop name | Almost awesome workshop |
|
||||
| Description | Invalid grade to pass is set here |
|
||||
|
@ -58,8 +55,7 @@ Feature: Setting grades to pass via workshop editing form
|
|||
|
||||
Scenario: Adding a new workshop with invalid value of a grade to pass
|
||||
Given I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I turn editing mode on
|
||||
And I am on "Course1" course homepage with editing mode on
|
||||
When I add a "Workshop" to section "1" and I fill the form with:
|
||||
| Workshop name | Almost awesome workshop |
|
||||
| Description | Invalid grade to pass is set here |
|
||||
|
@ -69,8 +65,7 @@ Feature: Setting grades to pass via workshop editing form
|
|||
|
||||
Scenario: Emptying grades to pass fields sets them to zero
|
||||
Given I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I turn editing mode on
|
||||
And I am on "Course1" course homepage with editing mode on
|
||||
And I add a "Workshop" to section "1" and I fill the form with:
|
||||
| Workshop name | Super awesome workshop |
|
||||
| Description | Grade to pass are set and then unset here |
|
||||
|
|
|
@ -27,7 +27,7 @@ Feature: Workshop submission and assessment
|
|||
| workshop | TestWorkshop | Test workshop description | c1 | workshop1 |
|
||||
# teacher1 sets up assessment form and changes the phase to submission
|
||||
When I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I edit assessment form in workshop "TestWorkshop" as:"
|
||||
| id_description__idx_0_editor | Aspect1 |
|
||||
| id_description__idx_1_editor | Aspect2 |
|
||||
|
@ -36,7 +36,7 @@ Feature: Workshop submission and assessment
|
|||
And I log out
|
||||
# student1 submits
|
||||
And I log in as "student1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
Then I should see "Submit your work"
|
||||
And I add a submission in workshop "TestWorkshop" as:"
|
||||
|
@ -46,21 +46,21 @@ Feature: Workshop submission and assessment
|
|||
And I log out
|
||||
# student2 submits
|
||||
And I log in as "student2"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I add a submission in workshop "TestWorkshop" as:"
|
||||
| Title | Submission2 |
|
||||
| Submission content | Some content |
|
||||
And I log out
|
||||
# student3 submits
|
||||
And I log in as "student3"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I add a submission in workshop "TestWorkshop" as:"
|
||||
| Title | Submission3 |
|
||||
| Submission content | Some content |
|
||||
And I log out
|
||||
# teacher1 allocates reviewers and changes the phase to assessment
|
||||
And I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And I should see "to allocate: 3"
|
||||
And I should see "There is at least one author who has not yet submitted their work"
|
||||
|
@ -82,7 +82,7 @@ Feature: Workshop submission and assessment
|
|||
And I log out
|
||||
# student1 assesses work of student2 and student3
|
||||
And I log in as "student1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And "//ul[@class='tasks']/li[div[@class='title' and contains(.,'Assess peers')]]/div[@class='details' and contains(.,'pending: 2') and contains(.,'total: 2')]" "xpath_element" should exist
|
||||
And I assess submission "Sam2" in workshop "TestWorkshop" as:"
|
||||
|
@ -92,7 +92,7 @@ Feature: Workshop submission and assessment
|
|||
| peercomment__idx_1 | Amazing |
|
||||
| Feedback for the author | Good work |
|
||||
And "//ul[@class='tasks']/li[div[@class='title' and contains(.,'Assess peers')]]/div[@class='details' and contains(.,'pending: 1') and contains(.,'total: 2')]" "xpath_element" should exist
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I assess submission "Sam3" in workshop "TestWorkshop" as:"
|
||||
| grade__idx_0 | 9 / 10 |
|
||||
| peercomment__idx_0 | Well done |
|
||||
|
@ -103,7 +103,7 @@ Feature: Workshop submission and assessment
|
|||
And I log out
|
||||
# student2 assesses work of student1
|
||||
And I log in as "student2"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And "//ul[@class='tasks']/li[div[@class='title' and contains(.,'Assess peers')]]/div[@class='details' and contains(.,'pending: 1') and contains(.,'total: 1')]" "xpath_element" should exist
|
||||
And I assess submission "Sam1" in workshop "TestWorkshop" as:"
|
||||
|
@ -116,7 +116,7 @@ Feature: Workshop submission and assessment
|
|||
And I log out
|
||||
# teacher1 makes sure he can see all peer grades
|
||||
And I log in as "teacher1"
|
||||
And I am on course page "Course1"
|
||||
And I am on "Course1" course homepage
|
||||
And I follow "TestWorkshop"
|
||||
And I should see grade "52" for workshop participant "Sam1" set by peer "Sam2"
|
||||
And I should see grade "60" for workshop participant "Sam2" set by peer "Sam1"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue