Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 3.11.x will end 14 Nov 2022 (12 months plus 6 months extension).
  • Bug fixes for security issues in 3.11.x will end 13 Nov 2023 (18 months plus 12 months extension).
  • PHP version: minimum PHP 7.3.0 Note: minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is supported too.

Class: giftformat_test  - X-Ref

Unit tests for the GIFT import/export format.

assert_same_gift($expectedtext, $text)   X-Ref
No description

test_import_essay()   X-Ref
No description

test_export_essay()   X-Ref
No description

test_import_match()   X-Ref
No description

test_export_match()   X-Ref
No description

test_import_multichoice($numberingstyle)   X-Ref
Test import of multichoice question in GIFT format

param: string $numberingstyle multichoice numbering style to set for qtype_multichoice

numberingstyle_provider()   X-Ref
Return a list of numbering styles (see question/type/multichoice/questiontype.php
for valid choices)

return: array Array of 1-element arrays of qtype_multichoice numbering styles

test_import_multichoice_multi()   X-Ref
No description

test_import_multichoice_multi_tricky()   X-Ref
No description

test_export_multichoice()   X-Ref
No description

test_export_multichoice_multi_tricky()   X-Ref
No description

test_import_numerical()   X-Ref
No description

test_export_numerical()   X-Ref
No description

test_import_shortanswer()   X-Ref
No description

test_import_shortanswer_with_general_feedback()   X-Ref
No description

test_export_shortanswer()   X-Ref
No description

test_export_shortanswer_with_general_feedback()   X-Ref
No description

test_import_truefalse()   X-Ref
No description

test_import_truefalse_true_answer1()   X-Ref
No description

test_import_truefalse_true_answer2()   X-Ref
No description

test_export_truefalse()   X-Ref
No description

test_export_backslash()   X-Ref
No description

test_import_backslash()   X-Ref
No description

test_import_pre_content()   X-Ref
No description

test_import_question_with_tags()   X-Ref
No description

extract_idnumber_and_tags_from_comment_testcases()   X-Ref
Data provider for test_extract_idnumber_and_tags_from_comment.

return: array the test cases.

test_extract_idnumber_and_tags_from_comment(string $expectedidnumber, array $expectedtags, string $comment)   X-Ref
Test extract_idnumber_and_tags_from_comment.

param: string $expectedidnumber the expected idnumber.
param: array $expectedtags the expected tags.
param: string $comment the comment to parse.

test_export_question_with_tags_and_idnumber()   X-Ref
No description