411 Commits

Author SHA1 Message Date
Andrew Nicols
5be481d1d0
MDL-81520 core: Fix test finality 2024-12-11 12:30:21 +08:00
Jun Pataleta
49393a1608
MDL-78806 core: Remove redundant site name
MDL-78806 core: Remove redundant site name on page titles

* With the site name now being appended to the page titles, there
is no need to manually append the page titles.
2023-09-09 08:56:50 +08:00
Juan Leyva
8cbf1bb945 MDL-78263 airnotifier: keep notification name as part of the payload 2023-06-21 18:00:58 +02:00
Dani Palou
4cbe98f2e7
MDL-78368 airnotifier: Fix data encrypted several times
Backport of MDL-78054.
2023-05-26 21:46:35 +08:00
Jun Pataleta
9e582a6099 Merge branch 'MDL-78072-401' of https://github.com/andrewnicols/moodle into MOODLE_401_STABLE 2023-05-24 17:56:27 +08:00
Andrew Nicols
a1b37845a8
MDL-78072 core: Skip mobile encryption if Sodium is not available 2023-05-16 12:51:14 +08:00
Juan Leyva
d838917d28
MDL-78072 airnotifier: Apply payload size optimisation to all push
Backport of MDL-77893.

Co-authored by: Andrew Lyons <andrew@nicols.co.uk>
2023-05-09 13:07:10 +08:00
Juan Leyva
1af4ace4d6
MDL-78072 airnotifier: Allow configuring how to process encrypted notifs
Backport of MDL-77893.

Co-authored by: Andrew Lyons <andrew@nicols.co.uk>
2023-05-09 13:07:09 +08:00
Juan Leyva
5c85fb975d
MDL-78072 airnotifier: Leave only message data processed by: Airnotifier
Backport of MDL-77893.

Co-authored by: Andrew Lyons <andrew@nicols.co.uk>
2023-05-09 13:07:09 +08:00
Alex Morris
6ccb50ea9d
MDL-78072 message_airnotifier: Add encrypted notifications
Backport of MDL-76722.

Co-authored by: Andrew Lyons <andrew@nicols.co.uk>
2023-05-09 12:25:47 +08:00
Andrew Nicols
cd48ae56c7 MDL-77559 js: Rebuild all JS with Node 16 2023-03-09 09:53:19 +08:00
Andrew Nicols
288620b0b4 MDL-75012 js: Full build of all grunt things 2023-03-02 12:15:25 +08:00
Cameron Ball
c0c478acb4 MDL-77123 message_airnotifier: Don't test configured providers 2023-02-02 14:49:51 +08:00
Jun Pataleta
d9cd25c2fb MDL-76497 upgrade: add the 4.1.0 separation line to all upgrade scripts 2022-12-01 08:59:07 +03:00
David Woloszyn
0be376fdc0 MDL-76183 lib: Update Github URLs 2022-12-01 08:59:05 +03:00
Jun Pataleta
00bae8b8a4 MDL-76403 versions: bump all versions and requires near release 2022-11-23 09:45:23 +08:00
Ferran Recio
2493b4f01a MDL-74800 message: fix invalid aria-label attributes 2022-08-08 14:46:42 +02:00
Jun Pataleta
3c6fdb1993 Merge branch 'MDL-71062-master' of https://github.com/sharidas/moodle 2022-07-13 11:39:08 +08:00
Sujith Haridasan
73d604369d MDL-71062 core: Step 1 deprecation of print_error function 2022-07-13 08:20:54 +05:30
Jun Pataleta
c09f96c8ef Merge branch 'MDL-67347-master' of https://github.com/mihailges/moodle 2022-07-12 17:17:08 +08:00
Eloy Lafuente (stronk7)
58b56e2395 MDL-71747 upgrade: remove all the < 3.9.0 upgrade steps
This just deletes all the upgrade steps previous to 3.9.0. Some
small adjustments, like tweaking globals can also be applied
when needed.

Also includes an upgrade step to prevent upgrading from any
version < 2020061500 (v3.9.0) as anti-cheating measure.

The next commits will proceed to deprecate / remove functions
that were exclusively (usually belonging to upgradelib) being
used by those, now removed, upgrade steps. This is the list
of code to remove and document in upgrade.txt files:

  - upgrade_analytics_fix_contextids_defaults()
  - upgrade_convert_hub_config_site_param_names()
  - upgrade_rename_prediction_actions_useful_incorrectly_flagged()
  - \mod_forum\task\refresh_forum_post_counts adhoc task.

And these is the code that has NOT been removed
because it may be needed later (no matter there aren't uses now):

  - \core_search\manager::clean_up_non_existing_area(), used by
  - \core\task\clean_up_deleted_search_area_task adhoc task
2022-07-07 19:16:37 +02:00
Alfonso Salces
db7178edca MDL-74674 core: create notification generators 2022-06-29 10:31:40 +02:00
Mihail Geshoski
4ef7fc3895 MDL-67347 lang: Final removal of deprecated strings in 3.9 2022-06-15 16:46:16 +08:00
Paul Holden
28e95ef63c MDL-71276 message_email: include alternate email in privacy export. 2022-05-16 09:41:32 +01:00
Eloy Lafuente (stronk7)
caf55abf17 MDL-74413 phpunit: Move more tests to use correct names and namespaces
Applied the following changes to various testcase classes:

- Namespaced with component[\level2-API]
- Moved to level2-API subdirectory when required.
- Fixed incorrect use statements with leading backslash.
- Remove file phpdoc block
- Remove MOODLE_INTERNAL if not needed.
- Changed code to point to global scope when needed.
- Fix some relative paths and comments here and there.
- All them passing individually.
- Complete runs passing too.

Special mention to:

- Moved to the level2 "privacy" namespace:
  - \mod_assign\privacy\feedback_legacy_polyfill_test
  - \mod_assign\privacy\submission_legacy_polyfill_test

- Moved to the level2 "task" namespace:
  - \core_message\task\migrate_message_data_test
  - \ltiservice_gradebookservices\task\cleanup_test
  - \message_email\task\send_email_test
  - \mod_lti\task\clean_access_tokens_test
  - \mod_workshop\task\cron_task_test

- Moved to the level2 "event" namespace:
  - \core_h5p\event\deleted_test
  - \core_h5p\event\viewed_test

- Renamed to a better name:
  - backup_forum_activity_task_test.php (missing "task")
2022-05-07 20:32:30 +02:00
Eloy Lafuente (stronk7)
76f5445451 MDL-74510 upgrade: add the 4.0.0 separation line to all upgrade scripts 2022-04-22 18:45:10 +02:00
Jun Pataleta
70f6b1605b MDL-74471 versions: bump all versions and requires near release 2022-04-13 10:37:36 +08:00
Andrew Nicols
4b388fc239 MDL-74235 core: Update core uses of activity icons to monologo 2022-04-07 12:56:14 +08:00
Frédéric Massart
bee1bb317e MDL-74169 core_message: Hide preferences link when permissions lacking 2022-03-21 18:37:45 +08:00
Andrew Nicols
e1b9d5f3cd MDL-73915 js: Drop support for IE and android
Moodle announced that support for IE would be dropped back in August
2020 with Moodle 3.9 but not active steps were taken at that time. That
decision was made in MDLSITE-6109 and this particular step was meant to
be taken in Moodle 3.10.

This is the first step taken to actively drop support for IE.

This commit also bumps the browser support pattern from 0.25% to 0.3%.
The percentage here includes any browser where at least this percentage
of users worldwide may be using a browser. In this case it causes
support for Android 4.3-4.4 to be dropped, which relate to Android
KitKat (released 2013).

This combination of changes means that all of the supported browsers in
our compatibility list support modern features including async,
for...of, classes, native Promises, and more which has a huge impact on
the ease of debugging code, and drastically reduces the minified file
size because a number of native Polyfills included by Babel are no
longer included.
2022-02-23 08:55:20 +08:00
Andrew Nicols
0a4047ab31 MDL-73915 js: Switch amd minification to terser
Unfortunately the babel minify-mangle plugin seems to be abandoned and
in certain circumstances can be very buggy. The only safe options are to
disable it, or to switch to a different minification library.

Not minifying our javascript is not ideal, so this commit updates the
javascript tasks to use a rollup, combined with babel, and terser.

Babel still converts code from ES/UMD/AMD to AMD modules with the
relevant browser support, whilst terser minifies the code.

The rollup bundler handles tracking and creation of sourcemaps, and
supports better parallelisation of the tasks.

Since the upgrade to Node LTS/Gallium requires an upgrade to @babel/core
and eslint, which change the built files anyway, this seems like the
ideal time to make this change.
2022-02-23 08:55:09 +08:00
Andrew Nicols
aa7f7957ea MDL-73915 js: Upgrade babel and eslint 2022-02-23 08:53:54 +08:00
Eloy Lafuente (stronk7)
3bb4a4009c MDL-73764 tool_xmldb: Regenerate all the files detected by the report
Note that, instead of going one by one to them from the XMLDB Editor
(load, makes some tiny change, save, revert the change, save), the
report includes a commented line that, once uncommented, does regenerate
the file while reporting.

I've left it there as a commodity for the developer.
2022-02-08 19:25:03 +01:00
Eloy Lafuente (stronk7)
7a0d024e60 MDL-73659 phpunit: restore_date, api, rule, plugin, manager & helper
All restore_date_test, api_test, rule_test, plugin_test,
manager_test, helper_test testcase classes:

- Namespaced with component[\level2-API]
- Moved to level2-API subdirectory when required.
- Fixed incorrect use statements with leading backslash.
- Remove file phpdoc block
- Remove MOODLE_INTERNAL if not needed.
- Changed code to point to global scope when needed.
- Fix some relative paths and comments here and there.
- All them passing individually.
- Complete runs passing too.

Special mention to:

- All restore_date_test cases have been put under xxx\backup
  level 2 (valid API) namespace.
2022-02-05 00:03:32 +01:00
Ilya Tregubov
57fe1a3099 Merge branch 'MDL-67853-master' of https://github.com/crazyserver/moodle 2022-01-27 16:41:19 +02:00
Pau Ferrer Ocaña
b4c75986ad MDL-67853 message: Adapt tests removing online/offline settings 2022-01-27 15:22:15 +01:00
Pau Ferrer Ocaña
d74bd798b6 MDL-67853 message: Remove on/offline settings on message preferences 2022-01-27 15:22:15 +01:00
Eloy Lafuente (stronk7)
100bc51f1d MDL-73485 phpunit: externallib, generator and filter tescase names
All externallib_test, generator_test and filter_test classes:

- Namespaced with component[\level2-API]
- Moved to level2-API subdirectory when required.
- Fixed incorrect use statements with leading backslash.
- Changed code to point to global scope when needed.
- Fix some relative paths and comments here and there.
- All them passing individually.
- Complete runs passing too.

Special mention to tests under testing/tests:

1) The core_testing component doesn't exist.
2) But testing/tests are allowed because there is a suite pointing to it (phpunit.xml).
3) So, the only possible namespace for them is "core".
4) And to avoid problems with other core testcases (under lib/tests)
   they have been renamed to have testing_xxxx as prefix.

Finally, also modified calendar/tests/events/events_test.php because it uses
some renamed (core_calendar_externallib_testcase => \core_calendar\externallib_test)
classes.
2022-01-21 19:48:23 +01:00
Eloy Lafuente (stronk7)
e4a2d9c1d4 MDL-73348 phpunit: normalize all privacy provider tests
As far as now all them have correct privacy level2 namespace:
- Move them to "privacy" subdir.
- Rename the files to "provider_test.php", this includes old
  privacy_test.php and privacy_provider_test.php files
- Rename the testcase to provider_test too (to match file name)

Also, change some relative paths and comments to point to new
locations.
2021-12-17 14:21:02 +01:00
Eloy Lafuente (stronk7)
57e6fb7ad9 MDL-73348 phpunit: privacy and privacy_provider testcase names
All privacy_test and privacy_provider_test classes:

- Namespaced with component\privacy.
- Fixed incorrect use statements with leading backslash.
- Changed code to point to global scope when needed.
- Renamed a few files to make all be privacy_test or privacy_provider_test.php
- All them passing individually.
- Complete runs passing too.
2021-12-17 14:21:02 +01:00
Juan Leyva
2d5ee7bf1a MDL-70083 message: Adapt tests to new number of default providers
We now have enough default providers, so no need to show a warning in that case
2021-11-05 08:51:26 +01:00
Dani Palou
2e61125a4a MDL-72586 message: New WebService get_unread_notification_count 2021-10-04 14:40:48 +02:00
Sara Arjona
f471a7d23a MDL-71473 message: Remove jabber output notification
Jabber is not widely used these days so message_jabber has been removed
from Moodle core.
2021-09-13 08:32:47 +02:00
Andrew Nicols
73754b8c39 Merge branch 'MDL-72143-master' of git://github.com/jleyva/moodle 2021-08-19 09:10:18 +02:00
Eloy Lafuente (stronk7)
39d9c8fdd4 Merge branch 'master-MDL-72210' of https://github.com/golenkovm/moodle 2021-08-19 09:10:17 +02:00
Mikhail Golenkov
227a831aa1 MDL-72210 phpunit: Remove excessive curl mock responses 2021-08-14 10:38:55 +10:00
David Mudrák
f9ee118e94 MDL-72325 user: Use the core_user::awaiting_action() in existing places
There were existing places each doing its own checks similar to the ones
covered by the newly added core_user::awaiting_action() method. This
patch replaces those custom checks with this new API call.
2021-08-12 13:05:38 +02:00
Juan Leyva
1f5ceda78e MDL-72143 airnotifier: Additional configuration check
Additional check for $CFG->noemailever
2021-07-28 09:38:18 +02:00
Andrew Nicols
776f4bd80c MDL-72179 behat: Make use of page resolvers 2021-07-26 15:14:28 +08:00
Andrew Nicols
4f422785c6 MDL-71113 javascript: Improve basic JS Documentation 2021-06-18 09:38:05 +08:00