See Release Notes
Long Term Support Release
Differences Between: [Versions 39 and 311] [Versions 39 and 400] [Versions 39 and 401] [Versions 39 and 402] [Versions 39 and 403]
Testing the H5P API.
Copyright: | 2020 Sara Arjona <sara@moodle.com> |
License: | http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
File Size: | 506 lines (18 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
api_testcase:: (10 methods):
test_delete_library()
delete_library_provider()
test_get_dependent_libraries()
get_dependent_libraries_provider()
test_get_library()
get_library_provider()
test_get_content_from_pluginfile_url()
test_create_content_from_pluginfile_url()
test_delete_content_from_pluginfile_url()
test_get_export_info_from_context_id()
Class: api_testcase - X-Ref
Test class covering the H5P API.test_delete_library(string $libraryname, int $expectedh5p, int $expectedlibraries,int $expectedcontents, int $expecteddependencies) X-Ref |
Test the behaviour of delete_library(). param: string $libraryname Machine name of the library to delete. param: int $expectedh5p Total of H5P contents expected after deleting the library. param: int $expectedlibraries Total of H5P libraries expected after deleting the library. param: int $expectedcontents Total of H5P content_libraries expected after deleting the library. param: int $expecteddependencies Total of H5P library dependencies expected after deleting the library. |
delete_library_provider() X-Ref |
Data provider for test_delete_library(). return: array |
test_get_dependent_libraries(string $libraryname, int $expectedvalue) X-Ref |
Test the behaviour of get_dependent_libraries(). param: string $libraryname Machine name of the library to delete. param: int $expectedvalue Total of H5P required libraries expected. |
get_dependent_libraries_provider() X-Ref |
Data provider for test_get_dependent_libraries(). return: array |
test_get_library(string $libraryname, bool $emptyexpected) X-Ref |
Test the behaviour of get_library(). param: string $libraryname Machine name of the library to delete. param: bool $emptyexpected Wether the expected result is empty or not. |
get_library_provider() X-Ref |
Data provider for test_get_library(). return: array |
test_get_content_from_pluginfile_url() X-Ref |
Test the behaviour of get_content_from_pluginfile_url(). |
test_create_content_from_pluginfile_url() X-Ref |
Test the behaviour of create_content_from_pluginfile_url(). |
test_delete_content_from_pluginfile_url() X-Ref |
Test the behaviour of delete_content_from_pluginfile_url(). |
test_get_export_info_from_context_id() X-Ref |
Test the behaviour of get_export_info_from_context_id(). |