This commit is contained in:
Andrew Nicols 2022-12-08 07:53:09 +08:00
commit 1e594c9777
4 changed files with 30 additions and 24 deletions

View file

@ -52,7 +52,7 @@
{{#questions}}
<li class="list-group-item text-truncate">
{{#icon}}{{#pix}} {{key}}, {{component}}, {{{alttext}}} {{/pix}}{{/icon}}
{{name}}
{{{name}}}
</li>
{{/questions}}
</ul>

View file

@ -25,17 +25,19 @@ Feature: Adding random questions to a quiz based on category and tags
| contextlevel | reference | name | questioncategory |
| Course | C1 | Subcategory | Questions Category 1 |
And the following "questions" exist:
| questioncategory | qtype | name | user | questiontext |
| Questions Category 1 | essay | question 1 name | admin | Question 1 text |
| Questions Category 1 | essay | question 2 name | teacher1 | Question 2 text |
| Subcategory | essay | question 3 name | teacher1 | Question 3 text |
| Subcategory | essay | question 4 name | teacher1 | Question 4 text |
| questioncategory | qtype | name | user | questiontext |
| Questions Category 1 | essay | question 1 name | admin | Question 1 text |
| Questions Category 1 | essay | question 2 name | teacher1 | Question 2 text |
| Subcategory | essay | question 3 name | teacher1 | Question 3 text |
| Subcategory | essay | question 4 name | teacher1 | Question 4 text |
| Questions Category 1 | essay | "listen" & "answer" | teacher1 | Question 5 text |
And the following "core_question > Tags" exist:
| question | tag |
| question 1 name | foo |
| question 2 name | bar |
| question 3 name | foo |
| question 4 name | bar |
| question | tag |
| question 1 name | foo |
| question 2 name | bar |
| question 3 name | foo |
| question 4 name | bar |
| "listen" & "answer" | foo |
Scenario: Available tags are shown in the autocomplete tag field
Given I am on the "Quiz 1" "mod_quiz > Edit" page logged in as "teacher1"
@ -80,6 +82,8 @@ Feature: Adding random questions to a quiz based on category and tags
And I click on "(See questions)" "link"
Then I should see "Questions Category 1"
And I should see "foo"
And I should see "question 1 name"
And I should see "\"listen\" & \"answer\""
Scenario: Teacher without moodle/question:useall should not see the add a random question menu item
Given the following "permission overrides" exist: