Skip to content

Commit

Permalink
MDL-67469 tool_dataprivacy: Put back missing test code
Browse files Browse the repository at this point in the history
This patch simply brings back the missing test code for
\tool_dataprivacy_api_testcase::test_approve_data_request_non_dpo_user()
  • Loading branch information
junpataleta committed Dec 6, 2019
1 parent 250ea6a commit 5b3ec84
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions admin/tool/dataprivacy/tests/api_test.php
Expand Up @@ -337,6 +337,11 @@ public function test_approve_data_request_non_dpo_user() {
$datarequest = api::create_data_request($student->id, api::DATAREQUEST_TYPE_EXPORT);

$requestid = $datarequest->get('id');

// Login as a user without DPO role.
$this->setUser($teacher);
$this->expectException(required_capability_exception::class);
api::approve_data_request($requestid);
}

/**
Expand Down

0 comments on commit 5b3ec84

Please sign in to comment.