From 4fca5dabb2b2e8b53bf43695089d26cfa7f3f3a7 Mon Sep 17 00:00:00 2001 From: Jake Dallimore Date: Mon, 10 Sep 2018 09:18:28 +0800 Subject: [PATCH] MDL-63658 core_favourites: introduce the favourites subsystem to core --- lang/en/favourites.php | 22 ++++++++++++++++++++++ lib/classes/component.php | 1 + lib/tests/component_test.php | 2 +- phpunit.xml.dist | 3 +++ 4 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 lang/en/favourites.php diff --git a/lang/en/favourites.php b/lang/en/favourites.php new file mode 100644 index 00000000000..b5d0a7e3942 --- /dev/null +++ b/lang/en/favourites.php @@ -0,0 +1,22 @@ +. +/** + * Strings for component 'favourites', language 'en', branch 'master' + * + * @package core_favourites + * @copyright 2018 Jake Dallimore + * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later + */ diff --git a/lib/classes/component.php b/lib/classes/component.php index f7debb8ed81..9284f7d5a01 100644 --- a/lib/classes/component.php +++ b/lib/classes/component.php @@ -442,6 +442,7 @@ $cache = '.var_export($cache, true).'; 'edufields' => null, 'enrol' => $CFG->dirroot.'/enrol', 'error' => null, + 'favourites' => $CFG->dirroot . '/favourites', 'filepicker' => null, 'fileconverter' => $CFG->dirroot.'/files/converter', 'files' => $CFG->dirroot.'/files', diff --git a/lib/tests/component_test.php b/lib/tests/component_test.php index 3e3bd9640f2..625279d1797 100644 --- a/lib/tests/component_test.php +++ b/lib/tests/component_test.php @@ -36,7 +36,7 @@ class core_component_testcase extends advanced_testcase { * this is defined here to annoy devs that try to add more without any thinking, * always verify that it does not collide with any existing add-on modules and subplugins!!! */ - const SUBSYSTEMCOUNT = 66; + const SUBSYSTEMCOUNT = 67; public function setUp() { $psr0namespaces = new ReflectionProperty('core_component', 'psr0namespaces'); diff --git a/phpunit.xml.dist b/phpunit.xml.dist index 8cc36edb6b3..60af5a0d630 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -47,6 +47,9 @@ lib/tests lib/ajax/tests + + favourites/tests + lib/form/tests