Línea 6... |
Línea 6... |
6 |
| fullname | shortname |
|
6 |
| fullname | shortname |
|
7 |
| Course 1 | C1 |
|
7 |
| Course 1 | C1 |
|
8 |
And the following "activities" exist:
|
8 |
And the following "activities" exist:
|
9 |
| activity | course | section | name |
|
9 |
| activity | course | section | name |
|
10 |
| quiz | C1 | 1 | Quiz 1 |
|
10 |
| quiz | C1 | 1 | Quiz 1 |
|
- |
|
11 |
| quiz | C1 | 1 | Quiz 2 |
|
Línea 11... |
Línea 12... |
11 |
|
12 |
|
12 |
Scenario: Quiz setting "Require the use of Safe Exam Browser" has all types, except "Use an existing template".
|
13 |
Scenario: Quiz setting "Require the use of Safe Exam Browser" has all types, except "Use an existing template".
|
13 |
When I am on the "Quiz 1" "quiz activity editing" page logged in as admin
|
14 |
When I am on the "Quiz 1" "quiz activity editing" page logged in as admin
|
14 |
And I expand all fieldsets
|
15 |
And I expand all fieldsets
|
Línea 36... |
Línea 37... |
36 |
| capability | quizaccess/seb:manage_seb_templateid |
|
37 |
| capability | quizaccess/seb:manage_seb_templateid |
|
37 |
| permission | Prevent |
|
38 |
| permission | Prevent |
|
38 |
| contextlevel | System |
|
39 |
| contextlevel | System |
|
39 |
| reference | |
|
40 |
| reference | |
|
40 |
And the following "user" exists:
|
41 |
And the following "user" exists:
|
41 |
| username | teacher |
|
42 |
| username | teacher |
|
42 |
| firstname | Teacher |
|
43 |
| firstname | Teacher |
|
43 |
| lastname | One |
|
44 |
| lastname | One |
|
44 |
And the following "course enrolment" exists:
|
45 |
And the following "course enrolment" exists:
|
45 |
| user | teacher |
|
46 |
| user | teacher |
|
46 |
| course | C1 |
|
47 |
| course | C1 |
|
47 |
| role | editingteacher |
|
48 |
| role | editingteacher |
|
48 |
And I log in as "teacher"
|
49 |
And I log in as "teacher"
|
49 |
# Create the quiz.
|
50 |
# Create the quiz.
|
50 |
When I add a quiz activity to course "Course 1" section "0" and I fill the form with:
|
51 |
When I add a quiz activity to course "Course 1" section "0" and I fill the form with:
|
51 |
| Name | My quiz |
|
52 |
| Name | My quiz |
|
52 |
Then I should not see "New Quiz"
|
53 |
Then I should not see "New Quiz"
|
Línea 78... |
Línea 79... |
78 |
Then I should not see "Show time"
|
79 |
Then I should not see "Show time"
|
79 |
Then I should not see "Show keyboard layout"
|
80 |
Then I should not see "Show keyboard layout"
|
80 |
Then I should not see "Show Wi-Fi control"
|
81 |
Then I should not see "Show Wi-Fi control"
|
81 |
Then I should not see "Enable audio controls"
|
82 |
Then I should not see "Enable audio controls"
|
82 |
Then I should not see "Mute on startup"
|
83 |
Then I should not see "Mute on startup"
|
- |
|
84 |
Then I should not see "Allow browser access to camera"
|
- |
|
85 |
Then I should not see "Allow browser access to microphone"
|
83 |
Then I should not see "Enable spell checking"
|
86 |
Then I should not see "Enable spell checking"
|
84 |
Then I should not see "Enable URL filtering"
|
87 |
Then I should not see "Enable URL filtering"
|
85 |
Then I should not see "Filter also embedded content"
|
88 |
Then I should not see "Filter also embedded content"
|
86 |
Then I should not see "Expressions allowed"
|
89 |
Then I should not see "Expressions allowed"
|
87 |
Then I should not see "Regex allowed"
|
90 |
Then I should not see "Regex allowed"
|
Línea 110... |
Línea 113... |
110 |
Then I should not see "Show time"
|
113 |
Then I should not see "Show time"
|
111 |
Then I should not see "Show keyboard layout"
|
114 |
Then I should not see "Show keyboard layout"
|
112 |
Then I should not see "Show Wi-Fi control"
|
115 |
Then I should not see "Show Wi-Fi control"
|
113 |
Then I should not see "Enable audio controls"
|
116 |
Then I should not see "Enable audio controls"
|
114 |
Then I should not see "Mute on startup"
|
117 |
Then I should not see "Mute on startup"
|
- |
|
118 |
Then I should not see "Allow browser access to camera"
|
- |
|
119 |
Then I should not see "Allow browser access to microphone"
|
115 |
Then I should not see "Enable spell checking"
|
120 |
Then I should not see "Enable spell checking"
|
116 |
Then I should not see "Enable URL filtering"
|
121 |
Then I should not see "Enable URL filtering"
|
117 |
Then I should not see "Filter also embedded content"
|
122 |
Then I should not see "Filter also embedded content"
|
118 |
Then I should not see "Expressions allowed"
|
123 |
Then I should not see "Expressions allowed"
|
119 |
Then I should not see "Regex allowed"
|
124 |
Then I should not see "Regex allowed"
|
Línea 140... |
Línea 145... |
140 |
Then I should not see "Show time"
|
145 |
Then I should not see "Show time"
|
141 |
Then I should not see "Show keyboard layout"
|
146 |
Then I should not see "Show keyboard layout"
|
142 |
Then I should not see "Show Wi-Fi control"
|
147 |
Then I should not see "Show Wi-Fi control"
|
143 |
Then I should not see "Enable audio controls"
|
148 |
Then I should not see "Enable audio controls"
|
144 |
Then I should not see "Mute on startup"
|
149 |
Then I should not see "Mute on startup"
|
- |
|
150 |
Then I should not see "Allow browser access to camera"
|
- |
|
151 |
Then I should not see "Allow browser access to microphone"
|
145 |
Then I should not see "Enable spell checking"
|
152 |
Then I should not see "Enable spell checking"
|
146 |
Then I should not see "Enable URL filtering"
|
153 |
Then I should not see "Enable URL filtering"
|
147 |
Then I should not see "Filter also embedded content"
|
154 |
Then I should not see "Filter also embedded content"
|
148 |
Then I should not see "Expressions allowed"
|
155 |
Then I should not see "Expressions allowed"
|
149 |
Then I should not see "Regex allowed"
|
156 |
Then I should not see "Regex allowed"
|
Línea 174... |
Línea 181... |
174 |
Then I should not see "Show time"
|
181 |
Then I should not see "Show time"
|
175 |
Then I should not see "Show keyboard layout"
|
182 |
Then I should not see "Show keyboard layout"
|
176 |
Then I should not see "Show Wi-Fi control"
|
183 |
Then I should not see "Show Wi-Fi control"
|
177 |
Then I should not see "Enable audio controls"
|
184 |
Then I should not see "Enable audio controls"
|
178 |
Then I should not see "Mute on startup"
|
185 |
Then I should not see "Mute on startup"
|
- |
|
186 |
Then I should not see "Allow browser access to camera"
|
- |
|
187 |
Then I should not see "Allow browser access to microphone"
|
179 |
Then I should not see "Enable spell checking"
|
188 |
Then I should not see "Enable spell checking"
|
180 |
Then I should not see "Enable URL filtering"
|
189 |
Then I should not see "Enable URL filtering"
|
181 |
Then I should not see "Filter also embedded content"
|
190 |
Then I should not see "Filter also embedded content"
|
182 |
Then I should not see "Expressions allowed"
|
191 |
Then I should not see "Expressions allowed"
|
183 |
Then I should not see "Regex allowed"
|
192 |
Then I should not see "Regex allowed"
|
Línea 204... |
Línea 213... |
204 |
Then I should see "Show time"
|
213 |
Then I should see "Show time"
|
205 |
Then I should see "Show keyboard layout"
|
214 |
Then I should see "Show keyboard layout"
|
206 |
Then I should see "Show Wi-Fi control"
|
215 |
Then I should see "Show Wi-Fi control"
|
207 |
Then I should see "Enable audio controls"
|
216 |
Then I should see "Enable audio controls"
|
208 |
Then I should not see "Mute on startup"
|
217 |
Then I should not see "Mute on startup"
|
- |
|
218 |
Then I should see "Allow browser access to camera"
|
- |
|
219 |
Then I should see "Allow browser access to microphone"
|
209 |
Then I should see "Enable spell checking"
|
220 |
Then I should see "Enable spell checking"
|
210 |
Then I should see "Enable URL filtering"
|
221 |
Then I should see "Enable URL filtering"
|
211 |
Then I should not see "Filter also embedded content"
|
222 |
Then I should not see "Filter also embedded content"
|
212 |
Then I should not see "Expressions allowed"
|
223 |
Then I should not see "Expressions allowed"
|
213 |
Then I should not see "Regex allowed"
|
224 |
Then I should not see "Regex allowed"
|
Línea 230... |
Línea 241... |
230 |
Then I should see "Regex blocked"
|
241 |
Then I should see "Regex blocked"
|
231 |
Then I should not see "Upload Safe Exam Browser config file"
|
242 |
Then I should not see "Upload Safe Exam Browser config file"
|
232 |
Then I should not see "Allowed browser exam keys"
|
243 |
Then I should not see "Allowed browser exam keys"
|
233 |
Then I should not see "Safe Exam Browser config template"
|
244 |
Then I should not see "Safe Exam Browser config template"
|
234 |
Then I should not see "Template 1"
|
245 |
Then I should not see "Template 1"
|
- |
|
246 |
|
- |
|
247 |
Scenario: Disable templates that are already in use and seeing their visibility in settings
|
- |
|
248 |
Given the following "quizaccess_seb > seb templates" exist:
|
- |
|
249 |
| name | enabled |
|
- |
|
250 |
| Template 1 | 1 |
|
- |
|
251 |
| Template 2 | 0 |
|
- |
|
252 |
# Set Quiz 1 template to Template 1
|
- |
|
253 |
When I am on the "Quiz 1" "quiz activity editing" page logged in as admin
|
- |
|
254 |
And I expand all fieldsets
|
- |
|
255 |
And I set the field "Require the use of Safe Exam Browser" to "Yes – Use an existing template"
|
- |
|
256 |
Then I should see "Safe Exam Browser config template"
|
- |
|
257 |
And the "Safe Exam Browser config template" select box should contain "Template 1"
|
- |
|
258 |
And the "Safe Exam Browser config template" select box should not contain "Template 2"
|
- |
|
259 |
And I set the field "Safe Exam Browser config template" to "Template 1"
|
- |
|
260 |
And I press "Save and return to course"
|
- |
|
261 |
# Disable Template 1
|
- |
|
262 |
And I navigate to "Plugins > Activity modules > Quiz > Safe Exam Browser templates" in site administration
|
- |
|
263 |
And I click on "Edit" "link" in the "Template 1" "table_row"
|
- |
|
264 |
And I set the field "Enabled" to "No"
|
- |
|
265 |
And I press "Save changes"
|
- |
|
266 |
# Check Quiz 1 is still using Template 1
|
- |
|
267 |
When I am on the "Quiz 1" "quiz activity editing" page logged in as admin
|
- |
|
268 |
And I expand all fieldsets
|
- |
|
269 |
And the field "Require the use of Safe Exam Browser" matches value "Yes – Use an existing template"
|
- |
|
270 |
Then I should see "Template 1"
|
- |
|
271 |
And the "Safe Exam Browser config template" select box should contain "Template 1"
|
- |
|
272 |
And the "Safe Exam Browser config template" select box should not contain "Template 2"
|
- |
|
273 |
# Check Quiz 3 cannot use any templates as they're all disabled
|
- |
|
274 |
When I am on the "Quiz 2" "quiz activity editing" page logged in as admin
|
- |
|
275 |
And I expand all fieldsets
|
- |
|
276 |
And the "Require the use of Safe Exam Browser" select box should not contain "Yes – Use an existing template"
|