1760 Commits

Author SHA1 Message Date
Andrew Nicols
d7d7fa8385 Merge branch 'MDL-70880' of git://github.com/paulholden/moodle 2021-02-18 10:47:05 +08:00
Eloy Lafuente (stronk7)
a72ea10b84 Merge branch 'MDL-70552-master' of git://github.com/ilyatregubov/moodle 2021-02-17 10:26:20 +01:00
Ilya Tregubov
729688b379 MDL-70552 core_message: Show popup for teachers when anonymous
user completed feedback.
2021-02-17 08:42:52 +02:00
Jun Pataleta
32ed88ad07 MDL-48269 messageoutput_email: Remove occurrences of hidepicture 2021-02-16 12:48:44 +08:00
Paul Holden
776863806f MDL-70880 message: preserve window scroll when close message drawer. 2021-02-14 19:27:10 +00:00
Shamim Rezaie
a6578dd64f MDL-70173 message: Fix empty link 2021-02-09 16:16:09 +11:00
Andrew Nicols
0377b0f9fa Merge branch 'MDL-64866-master' of git://github.com/ilyatregubov/moodle 2021-02-04 11:37:01 +08:00
Víctor Déniz
df4ca28e37 Merge branch 'MDL-65135' of https://github.com/paulholden/moodle 2021-01-25 13:48:52 +00:00
Ilya Tregubov
bf5dd33546 MDL-64866 message: Remove message/defaultoutputs.php
and final deprecation of admin_page_defaultmessageoutputs class.
2021-01-22 09:44:41 +02:00
Sara Arjona
7d24686e59 Merge branch 'MDL-69308' of https://github.com/stronk7/moodle 2021-01-14 12:03:30 +01:00
Paul Holden
5d778a7646 MDL-65135 message: use full date in messaging drawer for old messages.
Messages sent in previous years will now include the year portion of
the date string.
2021-01-14 08:01:07 +00:00
Eloy Lafuente (stronk7)
77342b96fc MDL-69308 upgrade: remove all the < 3.6.0 upgrade steps
This just deletes all the upgrade steps previous to 3.6.0. Some
small adjustments, like tweaking globals can also be applied
when needed.

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

Note that in this case, there wasn't any case of upgradelib
functions being used, hence we haven't to deprecate/remove
anything in codebase. When there is such a need, that is done
in separate commits (one for each function) and documented here.

See MDL-65809 commits for an example removing/deprecating a
good number of functions.
2021-01-13 19:11:19 +01:00
Ferran Recio
ce87be7db6 MDL-67782 message: fix messages max length 2021-01-12 17:14:33 +01:00
Jake Dallimore
3022dfa1b5 Merge branch 'MDL-69411-master' of git://github.com/dravek/moodle 2020-12-03 11:36:26 +08:00
Sara Arjona
2ae62e9a51 Merge branch 'MDL-69878-master' of git://github.com/bmbrands/moodle 2020-11-26 12:46:10 +01:00
David Matamoros
c99a148628 MDL-69411 core_message: Fix return structure for empty result set
Passing a timefrom higher than last message timecreated needs to
return a formatted response so it does not break ws.
2020-11-23 19:25:09 +01:00
Andrew Nicols
ba34d6e225 MDL-70148 behat: Update steps for keyboard 2020-11-17 15:14:43 +08:00
Bas Brands
35bd8622f7 MDL-69878 core_message: always show message drawer close icon 2020-11-11 15:39:16 +01:00
Eloy Lafuente (stronk7)
cb163538bb Merge branch 'MDL-70081-master' of git://github.com/jleyva/moodle into master 2020-11-03 01:24:45 +01:00
Juan Leyva
4bc5333b05 MDL-70081 airnotifier: Add missing device type in token registration 2020-10-31 13:07:30 +01:00
Matteo Scaramuccia
6e97e31423 MDL-70042 message_popup: Trivial savepoint comment cleanup 2020-10-28 22:44:07 +01:00
Matteo Scaramuccia
fad0a943b2 MDL-70042 message_popup: progress bar on upgrade only when necessary 2020-10-28 22:41:48 +01:00
Jake Dallimore
8006aac75c Merge branch 'MDL-68438_master' of https://github.com/t-schroeder/moodle 2020-10-22 09:30:28 +08:00
Eloy Lafuente (stronk7)
3a5641cb74 MDL-67673 phpunit: Remove deprecated assertEquals() params
The optional parameters of assertEquals() and assertNotEquals()
are deprecated in PHPUnit 8 (to be removed in PHPUnit 9):

- delta => use assertEqualsWithDelta()
- canonicalize => use assertEqualsCanonicalizing()
- ignoreCase => use assertEqualsIgnoringCase
- maxDepth => removed without replacement.

More info @ https://github.com/sebastianbergmann/phpunit/issues/3341

Initial search done with:

ag 'assert(Not)?Equals\(.*,.*,' --php

Then, running tests and fixing remaining cases.
2020-10-21 12:46:00 +02:00
Eloy Lafuente (stronk7)
40de097e65 MDL-67673 phpunit: Remove deprecated assertContains() uses on strings
Both assertContains() and assertNotContains() are deprecated in PHPUnit 8
for operations on strings. Also the optional case parameter is. All uses
must be changed to one of:

- assertStringContainsString()
- assertStringContainsStringIgnoringCase()
- assertStringNotContainsString()
- assertStringNotContainsStringIgnoringCase()

More info: https://github.com/sebastianbergmann/phpunit/issues/3422

Regexp to find all uses:

ag 'assert(Not)?Contains\('
2020-10-21 12:46:00 +02:00
Eloy Lafuente (stronk7)
a293b3aea8 MDL-67673 phpunit: Remove deprecated non-public attribute assertions
With PHPUnit 8 a good number of assertions, all them related with
operations on non-public attributes have been deprecated. And will
be removed with PHPUnit 9.

The main point is that unit tests shouldn't be testing non-public
APIs (good practice) and those assertions were an error originally.

See https://github.com/sebastianbergmann/phpunit/issues/3338 for
the complete list and other details.

When possible (the attributes being checked are public), the change
is simple, just switching to normal assertions.

When the attributes are not public we need to find a workaround
to be able to test the same using public APIs, or use Reflection,
or remove the tests.

For the records, this is the regexp used to find all the cases:

ag '>(assertAttribute|attribute\(|readAttributte|getStaticAttribute| \
    getObjectAttribute)' -G "test.php"
2020-10-21 12:46:00 +02:00
Eloy Lafuente (stronk7)
d95c378771 MDL-67673 phpunit: Remove expectedException annotations
While this is not strictly required, because removal will
happen in PHPUnit 9.0, we are already getting rid of all
uses in core.

From release notes:https://phpunit.de/announcements/phpunit-8.html

The annotations `@expectedException`, `@expectedExceptionCode`,
`@expectedExceptionMessage`, and `@expectedExceptionMessageRegExp`
are now deprecated.
Using these annotations will trigger a deprecation warning
in PHPUnit 8 and in PHPUnit 9 these annotations will be removed.

Also, all uses of expectExceptionMessageRegExp() has been moved
to expectExceptionMessageMatches(). See https://github.com/sebastianbergmann/phpunit/issues/3957

TODO: Various weirdness found while doing the changes with these tests:
- vendor/bin/phpunit lib/tests/exporter_test.php (created MDL-69700)
- vendor/bin/phpunit competency/tests/external_test.php (same issue than prev one)
- vendor/bin/phpunit question/engine/tests/questionengine_test.php (created MDL-69624)
- vendor/bin/phpunit lib/tests/event_test.php (created MDL-69688)
2020-10-21 12:46:00 +02:00
Eloy Lafuente (stronk7)
f6711bb394 MDL-67673 phpunit: Fix the return type of template methods
All the setup/teardown/pre/post/conditions template methods
now are required to return void. This was warned with phpunit 7
and now is enforced.

At the same time, fix a few wrong function names,
provider data and param types, return statements...
2020-10-21 12:45:59 +02:00
Tim Schroeder
8e0423d9a5
MDL-68438 message: fixed email format change with messaging disabled 2020-10-21 11:26:07 +02:00
Eloy Lafuente (stronk7)
19b0f08cc2 MDL-68070 messaging: Ensure that error is shown on first messages
Before there is a conversation, messages between users are sent
using core_message_send_instant_messages instead of
core_message_send_messages_to_conversation.

That method had an undefined $errormessage variable, ultimately
causing the problem detected on message_post_message()/message_send()
to never been returned by the external.

This just adds the same error than already existing conversations do,
but returning it as warning, for BC, JS will show it.
2020-10-14 18:57:16 +02:00
Jake Dallimore
b5b9bbc7fe Merge branch 'master_MDL-69848' of https://github.com/golenkovm/moodle 2020-10-14 09:41:39 +08:00
Eloy Lafuente (stronk7)
b673c0910a Merge branch 'MDL-68070-master_messaging_fix' of https://github.com/beenet-dev/moodle into master 2020-10-13 23:40:24 +02:00
Simon Mok
bf17107882 MDL-68070 messaging: Fix error when personal notification is disabled 2020-10-12 19:30:02 +08:00
Simey Lameze
1c0baed969 MDL-65743 lib: add XMPPHP namespace and update calls 2020-10-05 13:37:51 +08:00
Mikhail Golenkov
6edd064414 MDL-69848 upgrade: Delete notifications in chunks 2020-10-05 12:11:28 +11:00
Sara Arjona
32f5dbbb80 Merge branch 'MDL-69050-master-allowlist' of git://github.com/mudrd8mz/moodle into master 2020-10-01 14:51:11 +02:00
Sara Arjona
6bb0262ed8 Merge branch 'MDL-68098-master' of git://github.com/dpalou/moodle into master 2020-10-01 12:56:16 +02:00
David Mudrák
801ee23427 MDL-69050 lang: Improve the wording of the comments
Stop using the terms whitelist/blacklist when used to allow/deny things.
2020-09-24 19:41:58 +02:00
Dani Palou
25bc7a3d6b MDL-68098 ws: Add unit tests to test mathjax in WS 2020-09-23 11:18:41 +02:00
Dani Palou
8c84eeeeac MDL-68098 ws: Fix WebServices broken by filters HTML 2020-09-22 09:43:03 +02:00
Bas Brands
ae0f81f8d8 MDL-69454 core_search: message search 2020-09-21 11:54:51 +02:00
Bas Brands
1a2a52d121 MDL-69454 core_search: consistent navbar search 2020-09-21 10:15:11 +02:00
Sara Arjona
7c99f40d61 Merge branch 'MDL-69521' of https://github.com/stronk7/moodle into master 2020-09-09 08:08:06 +02:00
Eloy Lafuente (stronk7)
74ee34fd87 MDL-69521 core: Move all comments in code from 4.1 to 3.11 2020-09-08 18:59:30 +02:00
Mathew May
ee94aded30 MDL-63261 messaging: Final 3.6 deprecations 2020-09-07 09:10:46 +08:00
Andrew Nicols
f24aae4cad Merge branch 'MDL-67735-master' of git://github.com/bmbrands/moodle 2020-08-19 08:28:49 +08:00
Eloy Lafuente (stronk7)
fbb0767536 MDL-69475 versions: bump all versions and requires in master
version = 2021052500 release version
requires= 2021052500 same than version

Why 20210525? (25th May 2021) ?

Because master is going to be Moodle 4.0, to be released
on November 2021. And, until then, we are going to have
a couple of "intermediate" releases:

- Moodle 3.10 to be released 9th November 2020. (2020110900)

  This version will be using versions from today to 2020110900
  (once it's released the YYYYMMDD part stops advancing).

- Moodle 3.11 to be released 10th May 2021. (2021051000)

  This version will be using versions from 3.10 release to 2021051000
  (once it's released the YYYYMMDD part stops advancing).

That means that all versions from today to 2021051000 are going
to be used by those 2 "intermediate" releases (3.10 and 3.11).

And we cannot use them in master, because it's forbidden to have
any overlapping of versions between branches (or different upgrade
paths will fail).

So, get that 2021051000, let's add it a couple of weeks to cover
the on-sync period (or a 2 weeks delay max!) and, the first version
that master can "own" in exclusive (without any overlap) is, exactly,
25th May 2021, hence our 20210525.
2020-08-18 00:47:15 +02:00
Bas Brands
4394f9e358 MDL-67735 theme_boost: remove bs2 and bs4alpha compatibility css 2020-08-17 08:16:42 +00:00
Adrian Greeve
b713aa80b4 Merge branch 'MDL-68423-master' of git://github.com/ferranrecio/moodle 2020-08-13 11:02:04 +08:00
Eloy Lafuente (stronk7)
ff7ec42832 Merge branch 'MDL-67831-master' of git://github.com/bmbrands/moodle into master 2020-08-05 00:45:20 +02:00