diff --git a/lib/tests/behat/locking.feature b/lib/tests/behat/locking.feature index d6f19c89ce6..d886884f25e 100644 --- a/lib/tests/behat/locking.feature +++ b/lib/tests/behat/locking.feature @@ -40,55 +40,55 @@ Feature: Context freezing apply to child contexts Given I log in as "admin" And I am on "courseaa1" course homepage And I follow "faa1" - And I should see "Add a new discussion topic" + And "Add a new discussion topic" "button" should exist When I follow "Freeze this context" And I click on "Continue" "button" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa1" course homepage Then I should see "Turn editing on" When I follow "faa1b" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist When I am on "courseaa2" course homepage Then I should see "Turn editing on" When I follow "faa2" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist When I am on "courseb" course homepage Then I should see "Turn editing on" When I follow "fb" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist And I log out When I log in as "teacher" And I am on "courseaa1" course homepage And I follow "faa1" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa1" course homepage Then I should see "Turn editing on" When I follow "faa1b" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist When I am on "courseaa2" course homepage Then I should see "Turn editing on" When I follow "faa2" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist When I am on "courseb" course homepage Then I should see "Turn editing on" When I follow "fb" - Then I should see "Add a new discussion topic" + And "Add a new discussion topic" "button" should exist And I log out When I log in as "student1" And I am on "courseaa1" course homepage And I follow "faa1" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa1" course homepage When I follow "faa1b" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist When I am on "courseaa2" course homepage When I follow "faa2" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist When I am on "courseb" course homepage When I follow "fb" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist Scenario: Freeze course should freeze all children Given I log in as "admin" @@ -97,54 +97,54 @@ Feature: Context freezing apply to child contexts When I follow "Freeze this context" And I click on "Continue" "button" Then I should not see "Turn editing on" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa1" course homepage Then I should not see "Turn editing on" - And I should see "Unfreeze this context" + And "Unfreeze this context" "link" should exist in current page administration When I follow "faa1b" - Then I should not see "Add a new discussion topic" - And I should not see "Unfreeze this context" + Then "Add a new discussion topic" "button" should not exist + And "Unfreeze this context" "link" should not exist in current page administration When I am on "courseaa2" course homepage Then I should see "Turn editing on" When I follow "faa2" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist When I am on "courseb" course homepage Then I should see "Turn editing on" When I follow "fb" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist And I log out When I log in as "teacher" And I am on "courseaa1" course homepage And I follow "faa1" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa1" course homepage Then I should not see "Turn editing on" When I follow "faa1b" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa2" course homepage Then I should see "Turn editing on" When I follow "faa2" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist When I am on "courseb" course homepage Then I should see "Turn editing on" When I follow "fb" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist And I log out When I log in as "student1" And I am on "courseaa1" course homepage And I follow "faa1" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa1" course homepage When I follow "faa1b" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa2" course homepage When I follow "faa2" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist When I am on "courseb" course homepage When I follow "fb" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist Scenario: Freeze course category should freeze all children Given I log in as "admin" @@ -153,53 +153,53 @@ Feature: Context freezing apply to child contexts And I click on "Continue" "button" And I am on "courseaa1" course homepage And I should not see "Turn editing on" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa1" course homepage Then I should not see "Turn editing on" - And I should not see "Unfreeze this context" + And "Unfreeze this context" "link" should not exist in current page administration When I follow "faa1b" - Then I should not see "Add a new discussion topic" - And I should not see "Unfreeze this context" + Then "Add a new discussion topic" "button" should not exist + And "Unfreeze this context" "link" should not exist in current page administration When I am on "courseaa2" course homepage Then I should not see "Turn editing on" When I follow "faa2" - Then I should not see "Add a new discussion topic" - And I should not see "Unfreeze this context" + Then "Add a new discussion topic" "button" should not exist + And "Unfreeze this context" "link" should not exist in current page administration When I am on "courseb" course homepage Then I should see "Turn editing on" When I follow "fb" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist And I log out When I log in as "teacher" And I am on "courseaa1" course homepage Then I should not see "Turn editing on" And I follow "faa1" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa1" course homepage Then I should not see "Turn editing on" When I follow "faa1b" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa2" course homepage Then I should not see "Turn editing on" When I follow "faa2" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseb" course homepage Then I should see "Turn editing on" When I follow "fb" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist And I log out When I log in as "student1" And I am on "courseaa1" course homepage And I follow "faa1" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa1" course homepage When I follow "faa1b" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseaa2" course homepage When I follow "faa2" - Then I should not see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should not exist When I am on "courseb" course homepage When I follow "fb" - Then I should see "Add a new discussion topic" + Then "Add a new discussion topic" "button" should exist