MDL-77299 question: Added class properties that are not declared.

In PHP 8.2 and later, setting a value to an undeclared class property is
deprecated and emits a deprecation notice.
So we need to add missing class properties that still need to be declared.

Co-authored-by: Tim Hunt <[email protected]>
This commit is contained in:
Meirza
2023-03-01 10:09:09 +07:00
co-authored by Tim Hunt
parent 9ee4f8db8b
commit e4b24bdd79
27 changed files with 130 additions and 43 deletions
@@ -52,12 +52,6 @@ class questionattempt_test extends \advanced_testcase {
$this->qa = new question_attempt($this->question, $this->usageid);
}
protected function tearDown(): void {
$this->question = null;
$this->useageid = null;
$this->qa = null;
}
public function test_constructor_sets_maxmark() {
$qa = new question_attempt($this->question, $this->usageid);
$this->assertSame($this->question, $qa->get_question(false));