From dcb59c872cdff7375ee58cca9b4d2ee8a56b30bc Mon Sep 17 00:00:00 2001 From: Frederic Massart Date: Wed, 8 Oct 2014 16:16:01 +0800 Subject: [PATCH] MDL-45893 my: Specifically follow My home from block in Behat tests --- .../tests/behat/expand_my_courses_setting.feature | 10 +++++----- blocks/navigation/tests/behat/view_my_courses.feature | 4 ++-- my/tests/behat/add_blocks.feature | 2 +- my/tests/behat/reset_page.feature | 2 +- my/tests/behat/restrict_available_blocks.feature | 4 ++-- user/tests/behat/edituserpassword.feature | 2 +- 6 files changed, 12 insertions(+), 12 deletions(-) diff --git a/blocks/navigation/tests/behat/expand_my_courses_setting.feature b/blocks/navigation/tests/behat/expand_my_courses_setting.feature index b1a0b7b66703f..ad6e9f64b2bfd 100644 --- a/blocks/navigation/tests/behat/expand_my_courses_setting.feature +++ b/blocks/navigation/tests/behat/expand_my_courses_setting.feature @@ -22,7 +22,7 @@ Feature: Test expand my courses navigation setting Scenario: The My Courses branch is expanded on the My Moodle page by default When I log in as "student1" - And I follow "My home" + And I click on "My home" "link" in the "Navigation" "block" Then I should see "c1" in the "Navigation" "block" And I should see "c2" in the "Navigation" "block" And I should not see "c3" in the "Navigation" "block" @@ -33,8 +33,8 @@ Feature: Test expand my courses navigation setting And I set the following administration settings values: | Show My courses expanded on My home | 0 | And I log out - Given I log in as "student1" - And I follow "My home" + When I log in as "student1" + And I click on "My home" "link" in the "Navigation" "block" Then I should not see "c1" in the "Navigation" "block" And I should not see "c2" in the "Navigation" "block" And I should not see "c3" in the "Navigation" "block" @@ -45,8 +45,8 @@ Feature: Test expand my courses navigation setting And I set the following administration settings values: | Show My courses expanded on My home | 0 | And I log out - Given I log in as "student1" - And I follow "My home" + When I log in as "student1" + And I click on "My home" "link" in the "Navigation" "block" And I should not see "c1" in the "Navigation" "block" And I should not see "c2" in the "Navigation" "block" And I should not see "c3" in the "Navigation" "block" diff --git a/blocks/navigation/tests/behat/view_my_courses.feature b/blocks/navigation/tests/behat/view_my_courses.feature index a629d9eafa078..d20bbb0413639 100644 --- a/blocks/navigation/tests/behat/view_my_courses.feature +++ b/blocks/navigation/tests/behat/view_my_courses.feature @@ -37,7 +37,7 @@ Feature: View my courses in navigation block | Show my course categories | 0 | And I log out And I log in as "student1" - When I follow "My home" + When I click on "My home" "link" in the "Navigation" "block" Then I should not see "cat1" in the "Navigation" "block" And I should not see "cat2" in the "Navigation" "block" And I should see "c1" in the "Navigation" "block" @@ -53,7 +53,7 @@ Feature: View my courses in navigation block | Show my course categories | 1 | And I log out And I log in as "student1" - When I follow "My home" + When I click on "My home" "link" in the "Navigation" "block" Then I should see "cat1" in the "Navigation" "block" And I should see "cat3" in the "Navigation" "block" And I should not see "cat2" in the "Navigation" "block" diff --git a/my/tests/behat/add_blocks.feature b/my/tests/behat/add_blocks.feature index 740febfdd4c7c..f011fbf376dee 100644 --- a/my/tests/behat/add_blocks.feature +++ b/my/tests/behat/add_blocks.feature @@ -17,7 +17,7 @@ Feature: Add blocks to my home page | student1 | C1 | student | | student2 | C1 | student | And I log in as "student1" - And I follow "My home" + And I click on "My home" "link" in the "Navigation" "block" Scenario: Add blocks to page When I press "Customise this page" diff --git a/my/tests/behat/reset_page.feature b/my/tests/behat/reset_page.feature index 16920a78dbd67..291a87692f534 100644 --- a/my/tests/behat/reset_page.feature +++ b/my/tests/behat/reset_page.feature @@ -17,7 +17,7 @@ Feature: Reset my home page to default | student1 | C1 | student | | student2 | C1 | student | And I log in as "student1" - And I follow "My home" + And I click on "My home" "link" in the "Navigation" "block" Scenario: Add blocks to page and reset When I press "Customise this page" diff --git a/my/tests/behat/restrict_available_blocks.feature b/my/tests/behat/restrict_available_blocks.feature index abcd337c55bbb..7597b42e45371 100644 --- a/my/tests/behat/restrict_available_blocks.feature +++ b/my/tests/behat/restrict_available_blocks.feature @@ -18,7 +18,7 @@ Feature: Restrict which blocks can be added to My home Scenario: The comments block can be added to My home by default And I log in as "student1" - And I follow "My home" + And I click on "My home" "link" in the "Navigation" "block" And I press "Customise this page" Then the "Add a block" select box should contain "Comments" And the "Add a block" select box should contain "Courses" @@ -34,7 +34,7 @@ Feature: Restrict which blocks can be added to My home | block/html:myaddinstance | Prohibit | And I log out And I log in as "student1" - And I follow "My home" + And I click on "My home" "link" in the "Navigation" "block" And I press "Customise this page" Then the "Add a block" select box should not contain "Comments" And the "Add a block" select box should not contain "Courses" diff --git a/user/tests/behat/edituserpassword.feature b/user/tests/behat/edituserpassword.feature index 0c5232c939d89..4d5ee2c5d5eec 100644 --- a/user/tests/behat/edituserpassword.feature +++ b/user/tests/behat/edituserpassword.feature @@ -7,7 +7,7 @@ Feature: Enable/disable password field based on authentication selected. @javascript Scenario: Verify the password field is enabled/disabled based on authentication selected, in user edit advanced page. Given I log in as "admin" - And I follow "My home" + And I click on "My home" "link" in the "Navigation" "block" When I navigate to "Add a new user" node in "Site administration > Users > Accounts" Then the "newpassword" "field" should be enabled And I set the field "auth" to "Web services authentication"