| Línea 141... |
Línea 141... |
| 141 |
/**
|
141 |
/**
|
| 142 |
* Test delete questions have single/multiple version.
|
142 |
* Test delete questions have single/multiple version.
|
| 143 |
*
|
143 |
*
|
| 144 |
* @covers \qbank_deletequestion\helper::delete_questions
|
144 |
* @covers \qbank_deletequestion\helper::delete_questions
|
| 145 |
*/
|
145 |
*/
|
| 146 |
public function test_delete_question_has_multiple_version() {
|
146 |
public function test_delete_question_has_multiple_version(): void {
|
| 147 |
global $DB;
|
147 |
global $DB;
|
| 148 |
$qcategory = $this->qgenerator->create_question_category(['contextid' => $this->context->id]);
|
148 |
$qcategory = $this->qgenerator->create_question_category(['contextid' => $this->context->id]);
|
| 149 |
$question1 = $this->qgenerator->create_question('shortanswer', null, ['category' => $qcategory->id,
|
149 |
$question1 = $this->qgenerator->create_question('shortanswer', null, ['category' => $qcategory->id,
|
| 150 |
'name' => 'Question 1 version 1']);
|
150 |
'name' => 'Question 1 version 1']);
|
| 151 |
$question1v1id = $question1->id;
|
151 |
$question1v1id = $question1->id;
|