1937 Commits

Author SHA1 Message Date
Andrew Nicols
55126be4ad
MDL-81520 core: Fix test finality 2024-12-11 12:30:21 +08:00
Andrew Nicols
c6942c9bb7
MDL-81521 core: Update all possibly data providers to be static
Note: Some data providers could not be automatically be converted to
being static. These will be handled in a separate issue.
2024-11-18 10:24:55 +08:00
Michael Hawkins
b08fbf57fd
MDL-83352 message: Update usercantbemessaged string 2024-10-03 17:46:34 +07:00
Paul Holden
bfe4d189cb
MDL-82602 webservice: correct config link to enable for mobile. 2024-09-12 08:05:06 +01:00
David Mudrák
1e0f46a125 MDL-82599 lang: Use the fixed strings in tests, too 2024-08-02 17:44:42 +02:00
Andrew Nicols
09b9c2a5b9
MDL-82373 core_message: Make message drawer router behat-aware
The drawer router was modifying the DOM in a variety of ways and hiding
content, without any pendingJS checks. As a result, there were cases
where a part of the UI was not visible, but had been rendered and was in
the DOM.

This change wraps the router Go method in a pendingJS call that only
resolves when the router transition completes.

Additionally the lazy load manager had a similar issue.
2024-07-26 12:45:30 +08:00
Andrew Nicols
15d331c058
MDL-63670 core_message: Tests should not use another testcase as base 2024-06-27 08:55:33 +08:00
Huong Nguyen
6d717d9c8a
Merge branch 'MDL-81522_404' of https://github.com/stronk7/moodle into MOODLE_404_STABLE 2024-06-12 08:46:59 +07:00
Eloy Lafuente (stronk7)
091b458c52
MDL-81522 phpunit: Add missing void return type to all tests #2
This commit includes more changes, all them also adding the :void
return type to unit tests missing them.

The difference is that all these changes, while also detected
perfectly by the moodle.PHPUnit.TestReturnType sniff, were not
auto-fixed (like the previous commit ones), because all them
do include some "return" statement and, for safety, we don't
fix them.

All the cases have been visually inspected and confirmed that
the existing "return" statements always belong to anon
functions within the test body and not the test own return statement.
2024-06-11 12:18:05 +02:00
Eloy Lafuente (stronk7)
1093256560
MDL-81522 phpunit: Add missing void return type to all tests
While this change is not 100% required now, it's good habit
and we are checking for it since Moodle 4.4.

All the changes in this commit have been applied automatically
using the moodle.PHPUnit.TestReturnType sniff and are, exclusively
adding the ": void" return types when missing.
2024-06-11 12:18:04 +02:00
Huong Nguyen
83b9f0e29d MDL-81428 core: Display the correct status for the contact request 2024-06-10 17:08:22 +07:00
Jun Pataleta
8b976e77ce MDL-81616 upgrade: add the 4.4.0 separation line to all upgrade scripts 2024-04-23 15:24:02 +10:00
Jun Pataleta
a180dba314
MDL-81549 versions: bump all versions and requires near release 2024-04-17 00:03:29 +08:00
Jun Pataleta
49a37d198e
MDL-70829 theme_boost: Make context header icons decorative
The non-empty alt text for the icons of the context header buttons like
the "Message" and the "Add contact" buttons cause redundant information
to be read twice by screen readers when the buttons are rendered with
the icon and the button name. The icons need to be set as decorative by
setting an empty alt text for them.
* The presentation role is also unnecessary.
* The alt text is needed when the button gets rendered without the
button name text.
2024-04-12 11:21:03 +08:00
Sara Arjona
0447aa9144
Merge branch 'MDL-4188-main-2' of https://github.com/HuongNV13/moodle 2024-04-04 17:40:57 +02:00
Huong Nguyen
f64fda43d5
MDL-4188 behat: Turn off course welcome message
Turn off the course welcome message,
so we can easily test other messages.
2024-04-04 20:13:47 +07:00
Huong Nguyen
c4e07686ea
MDL-4188 core_message: Modify PHPUnit to turn off course welcome message 2024-04-04 20:13:47 +07:00
Andrew Nicols
e4a8ed5cc2
MDL-81144 core: Convert standard_after_main_region_html to hook 2024-04-02 10:23:43 +08:00
Daniel Ziegenberg
08027e408c
MDL-81281 phpunit: assertObjectHasAttribute is deprecated
To be integrated as part of MDL-81266

When running PHPUnit 9.6 we get the following deprecation warnings:
"assertObjectHasAttribute() is deprecated and will be removed in PHPUnit
10. Refactor your test to use assertObjectHasProperty() instead."

So we replace all instances of assertObjectHasAttribute with
assertObjectHasProperty.

PHPUnit justifies the change with:
> PHPUnit currently refers to "fields" (see above) as "attributes". This
> is (or will become) confusing considering the introduction of
> attributes in PHP 8 and their support in PHPUnit.  PHPUnit will be
> changed to use the term "property" instead of "attribute" where "field"
> is meant.

Signed-off-by: Daniel Ziegenberg <daniel@ziegenberg.at>
2024-03-25 16:21:45 +01:00
Daniel Ziegenberg
87267da39d
MDL-81281 phpunit: assertObjectNotHasAttribute is deprecated
To be integrated as part of MDL-81266

When running PHPUnit 9.6 we get the following deprecation warnings:
"assertObjectNotHasAttribute() is deprecated and will be removed in PHPUnit
10. Refactor your test to use assertObjectNotHasProperty() instead."

So we replace all instances of assertObjectNotHasAttribute with
assertObjectNotHasProperty.

PHPUnit justifies the change with:
> PHPUnit currently refers to "fields" (see above) as "attributes". This
> is (or will become) confusing considering the introduction of
> attributes in PHP 8 and their support in PHPUnit.  PHPUnit will be
> changed to use the term "property" instead of "attribute" where "field"
> is meant.

Signed-off-by: Daniel Ziegenberg <daniel@ziegenberg.at>
2024-03-25 16:21:07 +01:00
Sara Arjona
4d4007166c
Merge branch 'MDL-72923-master' of https://github.com/michael-milette/moodle 2024-03-18 16:56:54 +01:00
Jun Pataleta
3278ce7aba
Merge branch 'MDL-65292' of https://github.com/stronk7/moodle 2024-03-08 08:00:41 +08:00
Michael Milette
9c8f09e2d9 MDL-72923 message: Fixed levels of headings in messaging drawer. 2024-03-06 07:29:17 -05:00
Andrew Nicols
9e16225864
Merge branch 'MDL-80183' of https://github.com/paulholden/moodle 2024-03-06 14:04:30 +08:00
Eloy Lafuente (stronk7)
29a541724f
MDL-65292 style: Fix all the function declaration ordering
This has been generated running the following Sniff,
part of the Moodle's CodeSniffer standard:
- PSR2.Methods.MethodDeclaration

It just ensures all the function declarations have
the correct order for:
- abstract and final.
- visibility (public, protected, private).
- static.

So, all the lines modified by this commit are function declarations
and the only changes are in the positions of those keywords.
2024-02-28 23:47:47 +01:00
Eloy Lafuente (stronk7)
ba1f804ffa
MDL-65292 style: Fix all function declarations white space
This has been generated running the following Sniffs, all
them part of the Moodle's CodeSniffer standard:
- PSR12.Functions.ReturnTypeDeclaration
- PSR12.Functions.NullableTypeDeclaration
- moodle.Methods.MethodDeclarationSpacing
- Squiz.Whitespace.ScopeKeywordSpacing

All them are, exclusively, about correct spacing, so the changes
are, all them, only white space changes.

Only exceptions to the above are 3 changes what were setting the
return type in a new line, and, when that happens, the closing
parenthesis (bracket) has to go to the same line than the colon.
2024-02-28 23:33:26 +01:00
Pedro Jordao
25125bbfe2 MDL-80364 message: Change icon and background-color when item selected
Icon and background-color had contrast issues in the selected state.
2024-02-27 15:09:38 +01:00
Paul Holden
a1e9bd2dae
MDL-80183 message: improve ARIA labelling of total/unread counts. 2024-02-22 15:53:00 +00:00
Paul Holden
45f83c203f
MDL-80183 message: render user online status as an accessible icon. 2024-02-22 11:50:08 +00:00
Mikel Martín
a198884333 MDL-80259 theme_boost: Refactor badge helper classes for Bootstrap 5 2024-01-23 08:27:23 +01:00
Andrew Nicols
525212f2d2
MDL-78496 core: Address phpcs issues with upgrade.php files 2023-11-19 21:20:53 +08:00
Andrew Nicols
545b36cd4a
MDL-78496 upgrade: remove all the < 4.1.0 upgrade steps
Also includes an upgrade step to prevent upgrading from any
version < 2021112802 (v4.1.0) as anti-cheating measure.
2023-11-17 23:25:36 +08:00
Jun Pataleta
9beff03a96
MDL-79626 upgrade: add the 4.3.0 separation line to all upgrade scripts 2023-10-10 10:44:17 +08:00
Sara Arjona
9877a06246
Merge branch 'MDL-79551-master-rc' of https://github.com/junpataleta/moodle 2023-10-04 12:28:14 +02:00
Jun Pataleta
94bc2cd38b
MDL-79551 versions: bump all versions and requires near release 2023-10-04 13:57:17 +08:00
Paul Holden
77766f9c8a MDL-72249 message: stricter cleaning of processor type parameter. 2023-10-04 01:24:20 +00:00
Juan Leyva
83461bcf5f MDL-79557 message: Clean subject field content for get_messages WS 2023-10-02 13:10:52 +02:00
Sara Arjona
cc9430929d
MDL-77708 docs: Update references from docs.moodle.org/dev 2023-09-26 10:30:19 +02:00
Huong Nguyen
d3efd69dc1
Merge branch 'MDL-78993-master' of https://github.com/sarjona/moodle 2023-09-13 11:21:36 +07:00
Ilya Tregubov
94c9ce0595
Merge branch 'MDL-78806-master' of https://github.com/junpataleta/moodle 2023-09-13 10:54:54 +08:00
Sara Arjona
ff844ab7bd
MDL-78993 theme: Remove $CFG->svgicons
The $CFG->svgicons setting was introduced in Moodle 2.4 due to incomplete
SVG support in certain web browsers.
The landscape has evolved significantly since then, and all modern browsers
now handle SVG files correctly.
The $CFG->svgicons settings has been removed and the supports_svg() method
has been updated with currently supported browsers (IE support was removed
in Moodle 3.10).
2023-09-12 15:28:03 +02:00
Jun Pataleta
1eb8ee32bb
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:58:54 +08:00
Andrew Nicols
48bc688ccd
MDL-78324 core: Convert modals to use new static methods
This commit takes all modals which were not using the legacy
ModalFactory.create triggers and migrates them to the new Modal.create
method.
2023-09-09 00:04:11 +08:00
Paul Holden
092273751b
MDL-78792 message: access checks in processor fragment callback. 2023-08-10 18:31:50 +07:00
Andrew Nicols
f7eddfa583 Merge branch 'MDL-78263-master' of https://github.com/jleyva/moodle 2023-06-22 14:29:40 +02:00
Juan Leyva
bf6ef82fa0 MDL-78263 airnotifier: keep notification name as part of the payload 2023-06-15 17:27:36 +02:00
Andrew Nicols
c8a7a11230
MDL-78306 message: Convert notification_processor_settings modal to ESM 2023-06-14 21:41:50 +08:00
Helen Foster
06c5a6c883 MDL-78415 lang: Import fixed English strings (en_fix) 2023-06-08 09:59:04 +01:00
Meirza
99368d4173 MDL-77350 message: Added missing class properties
In PHP 8.2 and later, setting a value to an undeclared class property is
deprecated and emits a deprecation notice.
So we need to add missing class properties that still need to be declared.
2023-05-16 00:33:19 +07:00
Andrew Nicols
3b7ef3d287 Merge branch 'MDL-78054-master' of https://github.com/dpalou/moodle 2023-05-04 12:04:42 +08:00