@@ -58,6 +58,12 @@ Feature: Configuring the theme_boost_union plugin on the "Smart menus" page, app
58
58
And the following "system role assigns" exist:
59
59
| user | course | role |
60
60
| systemmanager | Acceptance test site | manager |
61
+ And the following "roles" exist:
62
+ | name | shortname | description |
63
+ | Visitor | visitor | My visitor role |
64
+ And I navigate to "Users > Permissions > User policies" in site administration
65
+ And I set the field "Role for visitors" to "Visitor (visitor)"
66
+ And I press "Save changes"
61
67
When I navigate to smart menus
62
68
And I should see "Quick links" in the "smartmenus" "table"
63
69
And I should see smart menu "Quick links" item "Resources" in location "Main, Menu, User, Bottom"
@@ -67,7 +73,7 @@ Feature: Configuring the theme_boost_union plugin on the "Smart menus" page, app
67
73
And I set the field "By role" to "<byrole>"
68
74
And I set the field "Context" to "<context>"
69
75
And I click on "Save changes" "button"
70
- And I should not see smart menu "Quick links" item "Resources" in location "Main, Menu, User, Bottom"
76
+ And I <adminshouldorshouldnot> see smart menu "Quick links" item "Resources" in location "Main, Menu, User, Bottom"
71
77
And I log out
72
78
And I log in as "coursemanager"
73
79
Then I <managershouldorshouldnot> see smart menu "Quick links" item "Resources" in location "Main, Menu, User, Bottom"
@@ -79,14 +85,21 @@ Feature: Configuring the theme_boost_union plugin on the "Smart menus" page, app
79
85
Then I <teachershouldorshouldnot> see smart menu "Quick links" item "Resources" in location "Main, Menu, User, Bottom"
80
86
And I log out
81
87
And I log in as "systemmanager"
82
- Then I should see smart menu "Quick links" item "Resources" in location "Main, Menu, User, Bottom"
88
+ Then I <systemshouldorshouldnot> see smart menu "Quick links" item "Resources" in location "Main, Menu, User, Bottom"
89
+ And I log in as "guest"
90
+ Then I <guestshouldorshouldnot> see smart menu "Quick links" item "Resources" in location "Main, Menu, Bottom"
91
+ And I log out
92
+ And I <visitorshouldorshouldnot> see smart menu "Quick links" item "Resources" in location "Main, Menu, Bottom"
83
93
84
94
Examples :
85
- | byrole | context | student1shouldorshouldnot | teachershouldorshouldnot | managershouldorshouldnot |
86
- | Manager | Any | should not | should not | should |
87
- | Manager , Student | Any | should | should not | should |
88
- | Manager , Student , Teacher | Any | should | should | should |
89
- | Manager , Student , Teacher | System | should not | should not | should not |
95
+ | byrole | context | student1shouldorshouldnot | teachershouldorshouldnot | managershouldorshouldnot | guestshouldorshouldnot | adminshouldorshouldnot | systemshouldorshouldnot | visitorshouldorshouldnot |
96
+ | Manager | Any | should not | should not | should | should not | should not | should | should not |
97
+ | Manager , Student | Any | should | should not | should | should not | should not | should | should not |
98
+ | Manager , Student , Teacher | Any | should | should | should | should not | should not | should | should not |
99
+ | Manager , Student , Teacher | System | should not | should not | should not | should not | should not | should | should not |
100
+ | Authenticated user | Any | should | should | should | should not | should | should | should not |
101
+ | Guest | Any | should not | should not | should not | should | should not | should not | should not |
102
+ | Visitor | Any | should not | should not | should not | should not | should not | should not | should |
90
103
91
104
@javascript
92
105
Scenario Outline : Smartmenu: Menu items: Rules - Show smart menu item based on the user assignment in single cohorts
0 commit comments