Open golenkovm opened 1 year ago
The following patch was applied to fix the issue, but feel free to implement the fix in your own way:
diff --git a/db/install.php b/db/install.php
index 287bab3..83b7934 100644
--- a/db/install.php
+++ b/db/install.php
@@ -25,5 +25,10 @@ function xmldb_filter_kaltura_install() {
global $CFG;
require_once("$CFG->libdir/filterlib.php");
- filter_set_global_state('kaltura', TEXTFILTER_ON);
+ // Do not enable the filter when running unit tests because some core
+ // tests expect a specific number of filters enabled.
+ if (!defined('PHPUNIT_TEST') || !PHPUNIT_TEST) {
+ filter_set_global_state('kaltura', TEXTFILTER_ON);
+ }
+
}
When running unit tests with
filter_kaltura
plugin installed the following core test is failing:It seems like it expects a specific number of filters enabled by default.