24455 Commits

Author SHA1 Message Date
Ryan Wyllie
5436b0ed02 MDL-61363 tag: allow tagging in different context to item 2018-03-07 10:31:46 +08:00
Andrew Nicols
79e4395888 MDL-38829 core: Rewrite xmlize unit tests
These changes adjust the unit tests to compare known values rather than
calculating them on the fly.

The unit test against a 'bad' source has been modified to simply check
for the relevant exception as PHP prevents any output on exceptions
anyway.
2018-03-07 09:40:11 +08:00
Andrew Nicols
475d4345f9 Merge branch 'MDL-61380-master' of git://github.com/rezaies/moodle 2018-03-07 09:00:15 +08:00
Eloy Lafuente (stronk7)
e28b586b9c Merge branch 'MDL-61557-master' of git://github.com/rezaies/moodle 2018-03-07 00:19:50 +01:00
Shamim Rezaie
1b63ff10f9 MDL-61380 behat: Added autocomplete_suggestions name selector 2018-03-07 06:52:01 +11:00
Kilian
533a7edeae MDL-38829 core: Unit test for xmlize using two sample xml files.
The file sample_questions.xml from moodle-stack is properly formed.
The file sample_questions_wrong.xml has mismatching tags.
Comparison is performed with recursive array comparison.
Error messages and returned data structures are compared.
Call with: phpunit lib/tests/xmlize_test.php
2018-03-06 15:36:14 +08:00
Kilian
7825ffb1d5 MDL-38829 core: fix for xmlize is unable to import xml files>10MB
Since version 2.7.3 the libxml library (https://bugs.php.net/bug.php?id=49660)
limits parsing in memory files to 10MB. Unfortunately the libxml option
LIBXML_PARSEHUGE to release the 10MB limit is not exposed to php. Through
using the sax parser which is typically used to parse directly from files but
instead chunking the string in memory xml files larger than 10MB can again
be parsed. I copied the exact behaviour of the previous routine
by Hans Anderson (http://www.hansanderson.com/contact/) so compatibility
should be maintained.
2018-03-06 15:36:08 +08:00
Kilian
e4d61d8321 MDL-38829 core: Remove xmlize from thirdpartylibs 2018-03-06 15:35:46 +08:00
Shamim Rezaie
536d4d5729 MDL-61557 Lib: Add get_top_level_parent_id function 2018-03-05 13:34:08 +11:00
Andrew Nicols
03d174d733 MDL-61268 core: Fix empty string DB cehck
(amended by stronk7 to use the helper better)
2018-03-02 16:31:11 +01:00
Adrian Greeve
8a844437bf MDL-61268 blocks: Unit tests for deprecated object update.
Unit tests for testing that the upgrade functions to change
the now deprecated object to stdClass works.
2018-03-02 09:22:05 +08:00
Adrian Greeve
e78849e837 MDL-61268 blocks: Fix corrupt configdata in block instances.
Old configuration data in the block instances is base64 encoded with
the deprecated object class instead of stdClass.
2018-03-02 09:22:05 +08:00
Shamim Rezaie
4fa49cc647 MDL-61380 Quiz: Adding a random question 2018-03-01 11:50:52 +11:00
Dan Marsden
1a11bf375c MDL-49417 enrol_cohort: use ajax searchable selector for cohorts. 2018-03-01 13:39:56 +13:00
Mihail Geshoski
757a889b24 MDL-60398 resource: Unable to download folder resource 2018-02-26 16:49:21 +08:00
Andrew Nicols
26d26413a0 MDL-61480 core: Check plugin installed before returning 2018-02-26 12:11:25 +08:00
Cameron Ball
40e53599b3 MDL-61394 core_scss: Null coalesce path to sassc setting 2018-02-22 08:30:54 +08:00
Andrew Nicols
2b32b1fea8 Merge branch 'MDL-61394-master' of git://git.cameron1729.xyz/moodle 2018-02-22 08:30:53 +08:00
Cameron Ball
eadebb2445
MDL-61394 core_scss: Add unit tests for SassC compilation
This patch also adds a test in theme_boost to verify that boost
can be succesfully compiled without errors by SassC.
2018-02-19 14:46:00 +08:00
Cameron Ball
4658220b2d
MDL-61394 Administration: Add experimental feature to use SassC 2018-02-19 14:39:11 +08:00
Simey Lameze
1451c07e05 MDL-61444 question: make question_has_capability_on support new caps 2018-02-19 14:21:49 +08:00
Simey Lameze
34cd75240e MDL-61444 question: add question tagmine and tagall capabilities 2018-02-19 14:21:45 +08:00
Marina Glancy
6bc6757084 MDL-56635 tags: use recordset since component may not be unique 2018-02-16 09:50:57 +08:00
Stephen Bourget
b4993d29f7 MDL-45837 Grades: Minor fixes to grade_letter events 2018-02-14 17:31:57 +01:00
David Monllao
4b140685ad Merge branch 'MDL-45837_master' of git://github.com/markn86/moodle 2018-02-13 07:48:16 +01:00
Andrew Nicols
486f7c9555 Merge branch 'MDL-61150' of git://github.com/stronk7/moodle 2018-02-13 09:01:31 +08:00
Andrew Nicols
b6c2829745 Merge branch 'MDL-61366' of git://github.com/timhunt/moodle 2018-02-12 15:17:29 +08:00
Andrew Nicols
1e41e6ddd9 Merge branch 'MDL-61135-master' of git://github.com/ryanwyllie/moodle 2018-02-12 11:34:56 +08:00
Andrew Nicols
ada9d0fb69 MDL-61305 modinfo: Add back missing require for course 2018-02-12 10:39:51 +08:00
Andrew Nicols
af5f446fa8 Merge branch 'MDL-61305-master' of https://github.com/sammarshallou/moodle 2018-02-12 08:17:49 +08:00
Eloy Lafuente (stronk7)
54a099e989 MDL-61150 xmldb: Let's check the PATH attribute of XMLDB files
Starting with Moodle 3.5 the XMLDB->PATH attribute is checked
to be correct and pointing to the correct plugin directory.

It only was used for writing PHP savepoints code, but better we
ask for strict correctness.

With this patch applied, neither the XMLDB Editor neither install
will be able to load a file with wrong PATH anymore.
2018-02-11 23:07:18 +01:00
Mark Nelson
e960152141 MDL-45837 core: minor tidy up to events 2018-02-09 12:13:48 +08:00
Stephen Bourget
31647f0cc9 MDL-45837 Grades: Add events for grade letters 2018-02-09 11:41:38 +08:00
Stephen Bourget
2f3b709859 MDL-45837 Grades: Add events for scales 2018-02-09 11:41:38 +08:00
sam marshall
08ec1b4e47 MDL-61305 Performance: Modinfo cache can get built in parallel
In a busy site it is possible that one user will access the site
while another is building modinfo cache. This can result in the
cache being built several times at once, potentially causing a
performance issue.
2018-02-08 14:45:55 +00:00
Andrew Nicols
a87c7c03ad Merge branch 'MDL-61377-master' of git://github.com/rezaies/moodle 2018-02-07 12:52:26 +08:00
Shamim Rezaie
38b1d6cdd9 MDL-61377 Core: Fixed faulty warning when using progress_bar 2018-02-07 14:47:18 +11:00
Tim Hunt
168635fb6f MDL-61366 setuplib: safely construct the ajax renderer when needed 2018-02-06 12:09:43 +00:00
David Monllao
d3e54578ea Merge branch 'MDL-52811_prevent_forcelang' of git://github.com/davosmith/moodle 2018-02-06 08:00:11 +01:00
Andrew Nicols
e742f93303 Merge branch 'MDL-61132-master' of git://github.com/rezaies/moodle 2018-02-06 14:33:41 +08:00
Simey Lameze
680d5c5be6 MDL-61133 core_question: new submit_tags_form webservice 2018-02-05 10:58:04 +08:00
Simey Lameze
f31804c01c MDL-61133 core_output: add fontawesome mapping for tags icon 2018-02-05 09:36:52 +08:00
Shamim Rezaie
869320c7f4 MDL-61132 Questions: Unit tests compatibility
Modified unit tests to adapt with "Top" categories.
2018-02-05 11:58:58 +11:00
Shamim Rezaie
3b8f3198de MDL-61132 Quiz: "Random" question from "Top" categories
* Support for adding ranodm questions from "Top" categories
2018-02-05 11:58:57 +11:00
Shamim Rezaie
9275220de3 MDL-61132 Questions: Question Bank amendments to cope with Top category
* Display "Top" categories in the category filter when listing questions in the question bank
* Prevent editing "Top" categories
* Prevent deleting "Top" categories
2018-02-05 11:58:52 +11:00
Shamim Rezaie
bb06397130 MDL-61132 Questions: Add "Top" categories by default when don't exist
Create "Top" categories along with the default categories when they don't exist
2018-02-05 11:53:36 +11:00
Shamim Rezaie
d2c4ff10bf MDL-61132 Questions: Upgrade step to add Top to existing contexts
Upgrade script to add a "Top" category as a real category to the question bank
2018-02-05 11:20:50 +11:00
Ryan Wyllie
99df051805 MDL-61135 templates: improve loading icon for loading templates 2018-02-02 03:58:49 +00:00
Ryan Wyllie
2328bcccde MDL-61135 javascript: fix modal body height resizing when loading 2018-02-02 03:57:25 +00:00
Yair Spielmann
ecce451878 MDL-52811 course: Require course:setforcedlanguage to force language. 2018-02-01 17:06:57 +00:00