Differences Between: [Versions 311 and 402] [Versions 400 and 402] [Versions 401 and 402]
Privacy tests for core_calendar.
Copyright: | 2018 Zig Tan <zig@moodle.com> |
License: | http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
File Size: | 834 lines (42 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
provider_test:: (11 methods):
setUp()
test_get_contexts_for_userid()
test_export_user_data()
test_export_user_preferences()
test_delete_data_for_all_users_in_context()
test_delete_data_for_user()
test_get_users_in_context()
test_delete_data_for_users()
create_test_standard_calendar_event()
create_test_action_calendar_event()
create_test_calendar_subscription()
Class: provider_test - X-Ref
Unit tests for calendar/classes/privacy/providersetUp() X-Ref |
Overriding setUp() function to always reset after tests. |
test_get_contexts_for_userid() X-Ref |
Test for provider::get_contexts_for_userid(). |
test_export_user_data() X-Ref |
Test for provider::export_user_data(). |
test_export_user_preferences() X-Ref |
Test for provider::test_export_user_preferences(). |
test_delete_data_for_all_users_in_context() X-Ref |
Test for provider::delete_data_for_all_users_in_context(). |
test_delete_data_for_user() X-Ref |
Test for provider::delete_data_for_user(). |
test_get_users_in_context() X-Ref |
Test that only users with a user context are fetched. |
test_delete_data_for_users() X-Ref |
Test that data for users in approved userlist is deleted. |
create_test_standard_calendar_event($eventtype, $userid, $time, $customname = '', $categoryid = 0, $courseid = 0, $groupid = 0) X-Ref |
Helper function to create a Standard Calendar Event. param: string $eventtype Calendar event type param: int $userid User Id param: int $time Timestamp value param: string $customname Custom name param: int $categoryid Course Category Id param: int $courseid Course Id param: int $groupid Group Id return: bool|calendar_event Standard Calendar Event created. |
create_test_action_calendar_event($eventtype, $courseid, $instanceid, $modulename, $userid, $time) X-Ref |
Helper function to create an Action Calendar Event. param: string $eventtype Calendar event type param: int $courseid Course Id param: int $instanceid Activity Module instance id param: string $modulename Activity Module name param: int $userid User Id param: int $time Timestamp value return: bool|calendar_event Action Calendar Event created. |
create_test_calendar_subscription($eventtype, $url, $userid, $categoryid = 0, $courseid = 0, $groupid = 0) X-Ref |
Helper function to create a Calendar Subscription. param: string $eventtype Calendar Subscription event type param: string $url Calendar Subscription URL param: int $userid User Id param: int $categoryid Category Id param: int $courseid Course Id param: int $groupid Group Id return: int Calendar Subscription Id |