-
Notifications
You must be signed in to change notification settings - Fork 181
Create issue, delete issue unit tests #709
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: MOODLE_404_STABLE
Are you sure you want to change the base?
Create issue, delete issue unit tests #709
Conversation
tests/event/events_test.php
Outdated
$sink = $this->redirectEvents(); | ||
|
||
// Trigger event manually. | ||
\mod_customcert\event\issue_created::create([ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rather than triggering this manually can we please call the functions that trigger this and then check the event is called?
tests/event/events_test.php
Outdated
$DB->delete_records('customcert_issues', ['id' => $issueid]); | ||
|
||
// Trigger event manually. | ||
\mod_customcert\event\issue_deleted::create([ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rather than triggering this manually can we please call the functions that trigger this and then check the event is called?
Please see comments I left and fix the Moodle Plugin CI complaints. |
@mdjnelson, please check if it is okay now. The one testcase that is failing is not related to this PR. |
This PR is made for #686
@mdjnelson, here is the clean PR for create and delete unit test.