mirror of
https://github.com/moodle/moodle.git
synced 2025-03-15 05:00:06 +01:00
MDL-77350 calendar: 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.
This commit is contained in:
parent
0d3a840154
commit
00bea84ed6
@ -1066,6 +1066,18 @@ class calendar_information {
|
||||
/** @var string The calendar's view mode. */
|
||||
protected $viewmode;
|
||||
|
||||
/** @var \stdClass course data. */
|
||||
public $course;
|
||||
|
||||
/** @var int day. */
|
||||
protected $day;
|
||||
|
||||
/** @var int month. */
|
||||
protected $month;
|
||||
|
||||
/** @var int year. */
|
||||
protected $year;
|
||||
|
||||
/**
|
||||
* Creates a new instance
|
||||
*
|
||||
|
@ -75,7 +75,10 @@ class event_factory_test extends \advanced_testcase {
|
||||
}
|
||||
|
||||
if ($expectedattributevalue) {
|
||||
$this->assertEquals($instance->testattribute, $expectedattributevalue);
|
||||
$this->assertEquals(
|
||||
$instance->get_description()->get_value(),
|
||||
$expectedattributevalue
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@ -368,7 +371,6 @@ class event_factory_test extends \advanced_testcase {
|
||||
'location' => 'Test location',
|
||||
],
|
||||
'actioncallbackapplier' => function(event_interface $event) {
|
||||
$event->testattribute = 'Hello';
|
||||
return $event;
|
||||
},
|
||||
'visibilitycallbackapplier' => function(event_interface $event) {
|
||||
@ -403,7 +405,6 @@ class event_factory_test extends \advanced_testcase {
|
||||
'location' => 'Test location',
|
||||
],
|
||||
'actioncallbackapplier' => function(event_interface $event) {
|
||||
$event->testattribute = 'Hello';
|
||||
return $event;
|
||||
},
|
||||
'visibilitycallbackapplier' => function(event_interface $event) {
|
||||
@ -438,7 +439,6 @@ class event_factory_test extends \advanced_testcase {
|
||||
'location' => 'Test location',
|
||||
],
|
||||
'actioncallbackapplier' => function(event_interface $event) {
|
||||
$event->testattribute = 'Hello';
|
||||
return $event;
|
||||
},
|
||||
'visibilitycallbackapplier' => function(event_interface $event) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user