Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 3.10.x will end 8 November 2021 (12 months).
  • Bug fixes for security issues in 3.10.x will end 9 May 2022 (18 months).
  • PHP version: minimum PHP 7.2.0 Note: minimum PHP version has increased since Moodle 3.8. PHP 7.3.x and 7.4.x are supported too.
/lib/tests/
FolderUp one level  
Folderbehat/
 
Foldercontent/
 
Folderevent/
 
Folderexternal/
 
Folderfixtures/
 
Folderother/
 
Folderoutput/
 
Folderperformance/
 
Folderplugininfo/
 
Fileaccesslib_has_capability_test.php            [source] [701 lines]   A collection of tests for accesslib::has_capability().
Fileaccesslib_test.php                           [source] [4555 lines]  Full functional accesslib test.
Fileadhoc_task_test.php                          [source] [485 lines]   This file contains the unittests for adhock tasks.
Fileadminlib_test.php                            [source] [132 lines]   Unit tests for parts of adminlib.php.
Fileadmintree_test.php                           [source] [437 lines]   Unit tests for those parts of adminlib.php that implement the admin tree functionality.
Fileajaxlib_test.php                             [source] [129 lines]   Code quality unit tests that are fast enough to run each time.
Fileanalysers_test.php                           [source] [291 lines]   Unit tests for core analysers.
Fileantivirus_test.php                           [source] [229 lines]   Tests for antivirus manager.
Fileauthlib_test.php                             [source] [477 lines]   Authentication related tests.
Fileblocklib_test.php                            [source] [858 lines]   Tests for the block_manager class in ../blocklib.php.
Filecalendar_cron_task_test.php                  [source] [82 lines]    Contains the class containing unit tests for the calendar cron task.
Filecheck_test.php                               [source] [64 lines]    Check API unit tests
Fileclient_test.php                              [source] [125 lines]   
Filecollator_test.php                            [source] [333 lines]   Collator unit tests.
Filecompletion_daily_task_test.php               [source] [125 lines]   Contains the class containing unit tests for the daily completion cron task.
Filecompletionlib_test.php                       [source] [1123 lines]  Completion tests.
Filecomponent_test.php                           [source] [846 lines]   core_component related tests.
Filecomponentlib_test.php                        [source] [185 lines]   Unit tests for /lib/componentlib.class.php.
Fileconfigonlylib_test.php                       [source] [154 lines]   Unit tests for config only library functions-
Filecontent_test.php                             [source] [119 lines]   Unit tests for core\content class.
Filecore_media_player_native_test.php            [source] [163 lines]   Test for core_media_player_native.
Filecore_renderer_template_exploit_test.php      [source] [462 lines]   Unit tests for core renderer render template exploit.
Filecoverage.php                                 [source] [53 lines]    Coverage information for the core subsystem.
Filecronlib_test.php                             [source] [186 lines]   Unit tests for the cron.
Filecsslib_test.php                              [source] [59 lines]    This file contains the unittests for the css optimiser in csslib.php
Filecsvclass_test.php                            [source] [148 lines]   Tests csv import and export functions.
Filecurl_security_helper_test.php                [source] [300 lines]   Unit tests for /lib/classes/curl/curl_security_helper.php.
Filecustomcontext_test.php                       [source] [138 lines]   Code quality unit tests that are fast enough to run each time.
Filedataformat_test.php                          [source] [115 lines]   Tests for the dataformat plugins
Filedatalib_test.php                             [source] [980 lines]   Test for various bits of datalib.php.
Filedatalib_update_with_unique_index_test.php    [source] [129 lines]   Tests for {@link decompose_update_into_safe_changes()} and {@link update_field_with_unique_index()}.
Filedate_legacy_test.php                         [source] [348 lines]   Tests legacy Moodle date/time functions.
Filedate_test.php                                [source] [567 lines]   Tests core_date class.
Fileeditorlib_test.php                           [source] [60 lines]    Tests editors subsystem.
Fileenvironment_test.php                         [source] [235 lines]   Moodle environment test.
Fileevent_context_locked_test.php                [source] [109 lines]   Unit tests for the context locking events.
Fileevent_course_module_instance_list_viewed.php [source] [76 lines]    Tests for base course module instance list viewed event.
Fileevent_course_module_viewed.php               [source] [95 lines]    Tests for base course module viewed event.
Fileevent_deprecated_test.php                    [source] [45 lines]    Tests for deprecated events. Please add tests for deprecated events in this file.
Fileevent_grade_deleted_test.php                 [source] [88 lines]    Tests the \core\event\grade_deleted event.
Fileevent_profile_field_test.php                 [source] [393 lines]   Tests the events related to the user profile fields and categories.
Fileevent_test.php                               [source] [991 lines]   Tests for event manager, base event and observers.
Fileevent_unknown_logged_test.php                [source] [53 lines]    Tests for event manager, base event and observers.
Fileevent_user_graded_test.php                   [source] [238 lines]   Tests the \core\event\user_graded event.
Fileevent_user_password_updated_test.php         [source] [77 lines]    Tests for password changes event.
Fileevents_test.php                              [source] [397 lines]   Events tests.
Fileexporter_test.php                            [source] [281 lines]   Exporter class tests.
Fileexternallib_test.php                         [source] [694 lines]   Unit tests for /lib/externallib.php.
Filefilelib_test.php                             [source] [1779 lines]  Unit tests for /lib/filelib.php.
Filefilestorage_zip_archive_test.php             [source] [86 lines]    Unit tests for /lib/filestorage/zip_archive.php.
Filefiletypes_test.php                           [source] [253 lines]   Unit tests for /lib/classes/filetypes.php.
Filefilter_manager_test.php                      [source] [82 lines]    Unit tests for the {@link filter_manager} class.
Filefilterlib_test.php                           [source] [883 lines]   Tests for the parts of ../filterlib.php that involve loading the configuration from, and saving the configuration to, the database.
Fileformslib_test.php                            [source] [1000 lines]  Unit tests for /lib/formslib.php.
Filegdlib_test.php                               [source] [157 lines]   Test gd functionality.
Filegooglelib_test.php                           [source] [40 lines]    
Filegradelib_test.php                            [source] [304 lines]   Unit tests for /lib/gradelib.php.
Filegrades_externallib_test.php                  [source] [616 lines]   Unit tests for the grade API at /lib/classes/grades_external.php
Filegrading_externallib_test.php                 [source] [643 lines]   
Filegrouplib_test.php                            [source] [1884 lines]  Tests groups subsystems.
Fileh5p_get_content_types_task_test.php          [source] [86 lines]    Unit tests for the task that fetch the latest version of H5P content types.
Filehtml2text_test.php                           [source] [191 lines]   Tests our html2text hacks
Filehtml_writer_test.php                         [source] [255 lines]   Unit tests for the html_writer class.
Filehtmlpurifier_test.php                        [source] [513 lines]   Unit tests for the HTMLPurifier integration
Fileindicators_test.php                          [source] [354 lines]   Unit tests for core indicators.
Fileip_utils_test.php                            [source] [407 lines]   Contains the test class testing the \core\ip_utils static helper class functions.
Filejquery_test.php                              [source] [57 lines]    Test jQuery integration.
Fileldaplib_test.php                             [source] [474 lines]   ldap tests.
Filelicenselib_test.php                          [source] [345 lines]   licenselib tests.
Filelock_config_test.php                         [source] [102 lines]   lock unit tests
Filelock_test.php                                [source] [143 lines]   lock unit tests
Filemarkdown_test.php                            [source] [72 lines]    Test markdown text format.
Filemathslib_test.php                            [source] [318 lines]   Unit tests of mathslib wrapper and underlying EvalMath library.
Filemedialib_test.php                            [source] [499 lines]   Test classes for handling embedded media (audio/video).
Filemessage_test.php                             [source] [269 lines]   Test classes for \core\message\message.
Filemessageinbound_test.php                      [source] [171 lines]   Test classes for \core\message\inbound.
Filemessagelib_test.php                          [source] [1276 lines]  Tests for messagelib.php.
Fileminify_test.php                              [source] [123 lines]   core_minify related tests.
Filemodinfolib_test.php                          [source] [922 lines]   Unit tests for lib/modinfolib.php.
Filemoodle_page_test.php                         [source] [781 lines]   Tests for the moodle_page class.
Filemoodle_url_test.php                          [source] [340 lines]   Tests for moodle_url.
Filemoodlelib_test.php                           [source] [4958 lines]  Unit tests for (some of) ../moodlelib.php.
Filemustache_template_finder_test.php            [source] [198 lines]   Unit tests for lib/classes/output/mustache_template_finder.php
Filemustache_template_source_loader_test.php     [source] [526 lines]   Unit tests for lib/classes/output/mustache_template_source_loader.php
Filemyprofilelib_test.php                        [source] [275 lines]   Tests for myprofilelib apis.
Filenavigationlib_test.php                       [source] [656 lines]   Unit tests for lib/navigationlib.php
Filenotification_test.php                        [source] [131 lines]   Unit tests for core\notification.
Fileoauth2_test.php                              [source] [256 lines]   Tests for oauth2 apis (\core\oauth2\*).
Fileoutput_mustache_helper_collection_test.php   [source] [189 lines]   Unit tests for lib/classes/output/mustache_helper_collection
Fileoutputcomponents_test.php                    [source] [653 lines]   Unit tests for lib/outputcomponents.php.
Fileoutputfactories_test.php                     [source] [153 lines]   Unit tests for lib/outputfactories.php.
Fileoutputrequirementslib_test.php               [source] [137 lines]   Unit tests for lib/outputrequirementslibphp.
Filepersistent_test.php                          [source] [546 lines]   Persistent class tests.
Fileplugin_manager_test.php                      [source] [615 lines]   Unit tests for plugin manager class.
Fileportfoliolib_test.php                        [source] [170 lines]   Portfolio lib tests.
Fileprogress_display_test.php                    [source] [104 lines]   
Fileprogress_test.php                            [source] [427 lines]   Unit tests for the progress classes.
Fileqrcode_test.php                              [source] [54 lines]    Test QR code functionality.
Filequestionlib_test.php                         [source] [2152 lines]  Unit tests for (some of) ../questionlib.php.
Fileregex_test.php                               [source] [47 lines]    Test PHP regex capability - this may also serve as an example for devs.
Filerequirejs_test.php                           [source] [95 lines]    Unit tests for requirejs loader.
Filersslib_test.php                              [source] [142 lines]   These tests rely on the rsstest.xml file on download.moodle.org, from eloys listing: rsstest.xml: One valid rss feed. md5: 8fd047914863bf9b3a4b1514ec51c32c size: 32188
Filertlcss_test.php                              [source] [1266 lines]  Tests for the core_rtlcss class. The core_rtlcss class extends \MoodleHQ\RTLCSS\RTLCSS library which depends on sabberworm/php-css-parser library. This test verifies that css parsing works as expected should any of the above change.
Filescheduled_task_test.php                      [source] [611 lines]   This file contains the unittests for scheduled tasks.
Filescss_test.php                                [source] [154 lines]   This file contains the unittests for core scss.
Filesession_manager_test.php                     [source] [914 lines]   Unit tests for session manager class.
Filesession_redis_test.php                       [source] [314 lines]   Redis session tests. NOTE: in order to execute this test you need to set up Redis server and add configuration a constant to config.php or phpunit.xml configuration file:
Filesessionlib_test.php                          [source] [319 lines]   Unit tests for sessionlib.php file.
Filesetuplib_test.php                            [source] [552 lines]   Unit tests for setuplib.php
Filestatslib_test.php                            [source] [772 lines]   Tests for ../statslib.php
Filestring_manager_standard_test.php             [source] [241 lines]   Unit tests for localization support in lib/moodlelib.php
Filetablelib_test.php                            [source] [791 lines]   Test tablelib.
Filetask_database_logger_test.php                [source] [505 lines]   This file contains the unit tests for the database task logger.
Filetask_logging_test.php                        [source] [583 lines]   This file contains the unit tests for the task logging system.
Filetask_manager_test.php                        [source] [197 lines]   This file contains the unit tests for the task manager.
Filetask_running_test.php                        [source] [166 lines]   This file contains unit tests for the 'task running' data.
Filetext_test.php                                [source] [484 lines]   core_text unit tests.
Filetheme_config_test.php                        [source] [216 lines]   Tests the theme config class.
Filetime_splittings_test.php                     [source] [383 lines]   Unit tests for core time splitting methods.
Fileupdate_api_test.php                          [source] [151 lines]   Provides core_update_api_testcase class.
Fileupdate_checker_test.php                      [source] [291 lines]   Unit tests for the update checker.
Fileupdate_code_manager_test.php                 [source] [193 lines]   Provides core_update_code_manager_testcase class.
Fileupdate_validator_test.php                    [source] [373 lines]   Provides the unit tests class and some helper classes
Fileupgrade_util_test.php                        [source] [167 lines]   Upgrade utility class tests.
Fileupgradelib_test.php                          [source] [1529 lines]  Unit tests for the lib/upgradelib.php library.
Fileuser_menu_test.php                           [source] [109 lines]   
Fileuser_test.php                                [source] [773 lines]   Tests core_user class.
Fileuseragent_test.php                           [source] [2042 lines]  Tests the user agent class.
Fileweblib_format_text_test.php                  [source] [241 lines]   Unit tests for format_text defined in weblib.php.
Fileweblib_test.php                              [source] [880 lines]   Weblib tests.
Filexhprof_test.php                              [source] [85 lines]    Unit tests for xhprof.
Filexhtml_container_stack_test.php               [source] [135 lines]   Unit tests for xhtml stack.
Filexmlize_test.php                              [source] [71 lines]    Test xmlize xml import.