Línea 47... |
Línea 47... |
47 |
* Test the report viewed event.
|
47 |
* Test the report viewed event.
|
48 |
*
|
48 |
*
|
49 |
* It's not possible to use the moodle API to simulate the viewing of log report, so here we
|
49 |
* It's not possible to use the moodle API to simulate the viewing of log report, so here we
|
50 |
* simply create the event and trigger it.
|
50 |
* simply create the event and trigger it.
|
51 |
*/
|
51 |
*/
|
52 |
public function test_report_viewed() {
|
52 |
public function test_report_viewed(): void {
|
53 |
$course = $this->getDataGenerator()->create_course();
|
53 |
$course = $this->getDataGenerator()->create_course();
|
54 |
$context = \context_course::instance($course->id);
|
54 |
$context = \context_course::instance($course->id);
|
55 |
// Trigger event for loglive report viewed.
|
55 |
// Trigger event for loglive report viewed.
|
56 |
$event = \report_loglive\event\report_viewed::create(array('context' => $context));
|
56 |
$event = \report_loglive\event\report_viewed::create(array('context' => $context));
|