MDL-78806 mod_assign: Use new Behat step for checking page title

This commit is contained in:
Jun Pataleta 2023-09-09 20:45:08 +08:00
parent 86f29846d5
commit 83f56a0bed
No known key found for this signature in database
GPG Key ID: F83510526D99E2C7

View File

@ -21,14 +21,14 @@ Feature: In an assignment, page titles are informative
Scenario: I view an assignment as a student and take an action
When I am on the "History of ants" Activity page logged in as student1
Then "title[text() = 'C1: History of ants']" "xpath_element" should exist in the "head" "css_element"
Then the page title should contain "C1: History of ants"
And I press "Add submission"
And "title[text() = 'C1: History of ants - Edit submission']" "xpath_element" should exist in the "head" "css_element"
And the page title should contain "C1: History of ants - Edit submission"
Scenario: I view an assignment as a teacher and take an action
When I am on the "History of ants" Activity page logged in as teacher1
Then "title[text() = 'C1: History of ants']" "xpath_element" should exist in the "head" "css_element"
Then the page title should contain "C1: History of ants"
And I follow "View all submissions"
And "title[text() = 'C1: History of ants - Grading']" "xpath_element" should exist in the "head" "css_element"
And the page title should contain "C1: History of ants - Grading"
And I click on "Grade" "link" in the "Student 1" "table_row"
And "title[text() = 'C1: History of ants - Grading']" "xpath_element" should exist in the "head" "css_element"
And the page title should contain "C1: History of ants - Grading"