Search moodle.org's
Developer Documentation

See Release Notes

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

Differences Between: [Versions 310 and 403] [Versions 39 and 403]

(no description)

File Size: 235 lines (8 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 1 file
 admin/tool/dataprivacy/tests/data_privacy_testcase.php

Defines 1 class


Class: data_request_test  - X-Ref

Tests for the data_request persistent.

status_state_provider()   X-Ref
Data provider for testing is_resettable, and is_active.

return: array

test_pseudo_states_export(int $status, bool $resettable, bool $active)   X-Ref
Test the pseudo states of a data request with an export request.

param: int     $status
param: bool    $resettable
param: bool    $active

test_pseudo_states_delete(int $status, bool $resettable, bool $active)   X-Ref
Test the pseudo states of a data request with a delete request.

param: int     $status
param: bool    $resettable
param: bool    $active

test_can_reset_others($status)   X-Ref
Test the pseudo states of a data request.

param: int     $status

non_resettable_provider()   X-Ref
Data provider for states which are not resettable.

return: array

test_non_resubmit_request($status)   X-Ref
Ensure that requests which are not resettable cause an exception to be thrown.

param: int     $status

test_resubmit_request()   X-Ref
Ensure that a rejected request can be reset.


test_resubmit_active_request()   X-Ref
Ensure that an active request can be reset.


create_request_for_user_with_status(int $userid, int $type, int $status)   X-Ref
Create a data request for the user.

param: int     $userid
param: int     $type
param: int     $status
return: data_request