MDL-68579 core_h5p: Add a check to avoid execute task using BEHAT

This commit is contained in:
cescobedo
2020-05-11 10:15:01 +02:00
parent 5afef2670e
commit 74860627f2
@@ -59,6 +59,10 @@ class h5p_get_content_types_task extends scheduled_task {
* Execute the task.
*/
public function execute() {
// MDL-68579, avoid execute the task through behat tests.
if (defined('BEHAT_SITE_RUNNING')) {
return true;
}
$core = $this->get_core();