2321 Commits

Author SHA1 Message Date
Adrian Greeve
3f5489e014 Merge branch 'MDL-56653_enrol_meta_edit_instance_validation' of https://github.com/vtos/moodle 2020-11-19 11:07:27 +08:00
Andrew Nicols
ba34d6e225 MDL-70148 behat: Update steps for keyboard 2020-11-17 15:14:43 +08:00
Vitaly
d7d1ed65a5 MDL-56653 enrol_meta: a single DB query in edit_instance_validation
The 'edit_instance_validation()' method checks for existing meta enrolment instances.
The fix replaces DB queries in a loop for each course with a single query for all courses.
Also, a new testing method 'test_edit_instance_validation_with_existing_courses()'
was added to /enrol/meta/tests/plugin_test.php to test if the new implementation
returns an error in case of trying to save the already linked courses in the 'customint1' field.
2020-11-12 15:14:44 +03:00
Mihail Geshoski
253af8711d MDL-67837 backup: Add unit tests 2020-11-03 12:34:28 +01:00
Eloy Lafuente (stronk7)
d59487ded3 Merge branch 'MDL-69998-master-enfix' of git://github.com/mudrd8mz/moodle into master 2020-10-28 00:41:53 +01:00
Eloy Lafuente (stronk7)
96c572c5f3 NOBUG: Fixed SVG browser compatibility 2020-10-27 23:47:24 +01:00
Sara Arjona
54d718b2b0 MDL-69166 enrol_fee: fix behat string from fee to enrolment by payment 2020-10-27 15:00:30 +01:00
Sara Arjona
5c422a03b9 MDL-69166 enrol_fee: define default value to currency setting 2020-10-27 15:00:11 +01:00
Helen Foster
dd7a1d60e2 MDL-69998 lang: Import fixed English strings (en_fix) 2020-10-27 11:32:10 +01:00
Shamim Rezaie
ce7c648526 MDL-69166 core_payment: Add privacy implementation 2020-10-27 15:34:56 +11:00
Shamim Rezaie
f5d94d6305 MDL-69166 core_payment: Addressing various integration points
- Add help for 'payment account' field in the enrol instance form
- Remove MOODLE_INTERNALs when not necessary
- Add $userid to deliver_order
- Check if provider classes implement the provider interface
- Rename get_cost to get_payable
- get_payable returns payable object
- Improve registerEventListeners and added init
- Rename payment\provider to payment\service_provider
2020-10-27 15:34:56 +11:00
Shamim Rezaie
d5a9d6e520 MDL-69166 core_payment: Rename componentid to itemid 2020-10-27 15:34:56 +11:00
Marina Glancy
9ad96a63a4 MDL-69166 core_payment: addressing integration review 2020-10-27 15:34:55 +11:00
Shamim Rezaie
61766b3d11 MDL-69166 core_payment: Add paymentarea to the payment subsystem 2020-10-27 14:40:49 +11:00
Marina Glancy
409857a42f MDL-69166 core_payment: archiving accounts, triggering events, tests 2020-10-27 14:40:49 +11:00
Shamim Rezaie
73527fa213 MDL-69166 core_payment: Show cost on the modal when no gateway is chosen 2020-10-27 14:40:49 +11:00
Marina Glancy
1d479dc0cf MDL-69166 core_payment: improvements to api, small fixes 2020-10-27 14:40:49 +11:00
Marina Glancy
6ff3087fe6 MDL-69166 core_payment: add payment accounts 2020-10-27 14:40:49 +11:00
Shamim Rezaie
3c87455f4b MDL-69166 enrol_fee: Show a warning when no currency is supported 2020-10-27 14:40:49 +11:00
Shamim Rezaie
22a949196d MDL-69166 enrol_fee: Prevent adding instance if no currency is supported 2020-10-27 14:40:49 +11:00
Shamim Rezaie
9d773ee592 MDL-69166 enrol_fee: use template for payment btn & properly format cost 2020-10-27 14:37:28 +11:00
Shamim Rezaie
184d2d078a MDL-69166 enrol_fee: Implement callback functions for payment subsystem 2020-10-27 14:37:28 +11:00
Shamim Rezaie
e88e3b87be MDL-69166 enrol_fee: set a description for enrolment 2020-10-27 14:37:28 +11:00
Shamim Rezaie
8ef156b7dc MDL-69166 core_payment: post to process payment 2020-10-27 08:37:08 +11:00
Shamim Rezaie
e9de430907 MDL-69166 core_payment: display the gateways modal 2020-10-27 08:37:08 +11:00
Shamim Rezaie
a580b33738 MDL-69166 enrol_fee: An enrolment plugin that supports payments 2020-10-27 08:37:08 +11: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)
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
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
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
Eloy Lafuente (stronk7)
fd0b332db3 Merge branch 'MDL-69510-master' of https://github.com/snake/moodle into master 2020-09-08 15:27:29 +02:00
Jake Dallimore
0d6e5f2bc2 MDL-69510 admin: make ldap configuration warnings clear 2020-09-03 10:21:07 +08:00
Paul Holden
25ef8d4926 MDL-63387 enrol_cohort: show both roles names in instance config form. 2020-09-01 12:05:20 +01:00
Paul Holden
ee640d868a MDL-63387 enrol_manual: show both role names in enrol users dialog. 2020-09-01 12:05:20 +01: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
Jake Dallimore
af331f08d4 Merge branch 'MDL-45849-selfenrol' of https://github.com/Peterburnett/moodle 2020-07-16 16:27:01 +02:00
Jun Pataleta
c5438f982c MDL-57678 enrol_ldap: Replace usage of make_categories_options()
Replace with core_course_category::make_categories_list() instead.
2020-07-15 18:26:03 +08:00
Peter Burnett
37c99bd07e MDL-45849 enrol_self: Added self enrol capability 2020-07-10 11:52:10 +10:00
Víctor Déniz Falcón
d07fb8b9e8 MDL-69093 enrol_manual: added check for allowed roles a user can assign 2020-07-07 08:32:39 +02:00
Helen Foster
38d5e3db1b MDL-69130 lang: Import fixed English strings (en_fix)
Significant string change:

- presentationoraltrequired,atto_image - wording changed to mention
  'decorative only' checkbox
2020-06-25 21:54:13 +02:00
Eloy Lafuente (stronk7)
b764343e5a MDL-69044 upgrade: add 3.9.0 separation line to all upgrade scripts 2020-06-14 13:08:09 +02:00
Jake Dallimore
337e2e2b23 Merge branch 'MDL-68973' of https://github.com/stronk7/moodle 2020-06-10 16:13:57 +08:00
Andrew Nicols
a9075379d8 MDL-68977 enrol_manual: Add pending promises to enrol modal 2020-06-10 08:16:03 +08:00
Eloy Lafuente (stronk7)
115cc0214f MDL-68973 versions: bump all versions and requires near release
version = 2020061500 release version
requires= 2020060900 current rc1 (week7roll1) version
2020-06-09 16:23:09 +02:00
Andrew Nicols
eb087fc5de MDL-68951 user: Add appropriate exceptions for table/participants 2020-06-08 09:35:39 +08:00
Bas Brands
6a4ce7b0a3 MDL-67386 theme_boost: upgrade bootstrap to version 4.5.0 2020-05-25 15:48:17 +02:00