Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.2.x will end 22 April 2024 (12 months).
  • Bug fixes for security issues in 4.2.x will end 7 October 2024 (18 months).
  • PHP version: minimum PHP 8.0.0 Note: minimum PHP version has increased since Moodle 4.1. PHP 8.1.x is supported too.

(no description)

File Size: 172 lines (7 kb)
Included or required:0 times
Referenced: 1 time
Includes or requires: 1 file
 mod/assign/tests/fixtures/testable_assign.php

Defines 1 class

externallib_advanced_testcase:: (2 methods):
  create_submission_for_testing_status()
  create_assign_with_student_and_teacher()


Class: externallib_advanced_testcase  - X-Ref

Base class for unit tests for external functions in mod_assign.

create_submission_for_testing_status(bool $submitforgrading = false, array $params = [])   X-Ref
Create a submission for testing the get_submission_status function.

param: bool $submitforgrading whether to submit for grading the submission
param: array $params Optional params to use for creating assignment instance.
return: array an array containing all the required data for testing

create_assign_with_student_and_teacher(array $params = [])   X-Ref
Create a course, assignment module instance, student and teacher and enrol them in
the course.

param: array $params parameters to be provided to the assignment module creation
return: array containing the course, assignment module, student and teacher