diff --git a/message/tests/behat/message_manage_notification_preferences.feature b/message/tests/behat/message_manage_notification_preferences.feature index c60d12a4998..ffbda7bb8c2 100644 --- a/message/tests/behat/message_manage_notification_preferences.feature +++ b/message/tests/behat/message_manage_notification_preferences.feature @@ -215,3 +215,15 @@ Feature: Manage notification preferences - Email And I open the notification popover # Confirm the submission notification is NOT visible. And I should not see "You have submitted your assignment submission for Test assignment name" in the "#nav-notification-popover-container" "css_element" + + Scenario: Toggle notification preferences hides/displays options + Given I log in as "admin" + When I follow "Preferences" in the user menu + And I click on "Notification preferences" "link" in the "#page-content" "css_element" + Then I should see "Subscribed forum posts" + And I navigate to "Messaging > Notification settings" in site administration + And I click on "Subscribed forum posts" "checkbox" + And I click on "Save changes" "button" + And I follow "Preferences" in the user menu + And I click on "Notification preferences" "link" in the "#page-content" "css_element" + And I should not see "Subscribed forum posts" diff --git a/message/tests/behat/message_preferences.feature b/message/tests/behat/message_preferences.feature index b7df3ba9129..185a012e64b 100644 --- a/message/tests/behat/message_preferences.feature +++ b/message/tests/behat/message_preferences.feature @@ -27,3 +27,15 @@ Feature: To be able to see and save user message preferences as admin And I follow "Preferences" in the user menu And I click on "Message preferences" "link" And the field "Email" matches value "0" + + Scenario: Only active plugins have corresponding columns on the User preferences notification settings + # Needed for Mobile column to appear on User preferences notification settings. + Given the following config values are set as admin: + | airnotifieraccesskey | test123 | + And I log in as "admin" + And I follow "Preferences" in the user menu + When I click on "Notification preferences" "link" in the "#page-content" "css_element" + # By default, web/popup is enabled. mobile/airnotifier is enabled using an earlier step while email is disabled. + Then "[data-processor-name='popup']" "css_element" should exist + And "[data-processor-name='email']" "css_element" should not exist + And "[data-processor-name='airnotifier']" "css_element" should exist