1. 10 Mar, 2021 1 commit
    • sam marshall's avatar
      MDL-45242 Lib: Replace calls to deprecated functions · 558cc1b8
      sam marshall authored
      In all cases changes have been kept to a minimum while not making
      the code completely horrible. For example, there are many instances
      where it would probably be better to rewrite a query entirely, but
      I have not done that (in order to reduce the risk of changes).
      558cc1b8
  2. 08 Mar, 2021 1 commit
  3. 22 Feb, 2021 1 commit
  4. 05 Feb, 2021 1 commit
  5. 03 Feb, 2021 1 commit
  6. 21 Jan, 2021 1 commit
  7. 20 Jan, 2021 2 commits
  8. 19 Jan, 2021 1 commit
  9. 06 Nov, 2020 1 commit
  10. 21 Oct, 2020 4 commits
    • Eloy Lafuente's avatar
      MDL-67673 phpunit: Remove deprecated assertEquals() params · 3a5641cb
      Eloy Lafuente authored
      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.
      3a5641cb
    • Eloy Lafuente's avatar
      MDL-67673 phpunit: Remove deprecated assertContains() uses on strings · 40de097e
      Eloy Lafuente authored
      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\('
      40de097e
    • Eloy Lafuente's avatar
      MDL-67673 phpunit: Remove expectedException annotations · d95c3787
      Eloy Lafuente authored
      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)
      d95c3787
    • Eloy Lafuente's avatar
      MDL-67673 phpunit: Remove deprecated assertInternalType() · f94195c3
      Eloy Lafuente authored
      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
      
      assertInternalType() is deprecated and will be removed in
      PHPUnit 9. Refactor your test to use assertIsArray(), assertIsBool(),
      assertIsFloat(), assertIsInt(), assertIsNumeric(), assertIsObject(),
      assertIsResource(), assertIsString(), assertIsScalar(),
      assertIsCallable(), or assertIsIterable() instead.
      f94195c3
  11. 29 Sep, 2020 1 commit
  12. 21 Sep, 2020 1 commit
  13. 20 Aug, 2020 1 commit
  14. 12 Aug, 2020 1 commit
  15. 20 May, 2020 1 commit
  16. 07 May, 2020 1 commit
  17. 06 Apr, 2020 1 commit
  18. 07 Mar, 2020 1 commit
  19. 05 Mar, 2020 1 commit
  20. 03 Dec, 2019 1 commit
  21. 12 Aug, 2019 1 commit
  22. 07 Aug, 2019 1 commit
  23. 14 Jun, 2019 1 commit
    • Nicolas Roeser's avatar
      MDL-64975 moodlelib: fix float formatting if decsep is ~ (tilde) · 76a3cf95
      Nicolas Roeser authored
      Commit 637da99e has introduced changes
      for removing trailing zeroes from the output of function format_float.
      Due to a small omission, the function causes a PHP warning when the
      string decsep is set to a tilde character ('~'). This is rarely the
      case.
      
      The bug lies in using PHP function preg_replace with a string that
      contains external input (in this case, including decsep), but without
      escaping it for PCRE processing.
      
      This commit fixes the function to also support a tilde character in
      string decsep. It also adds tests for having tilde as decimal separator.
      
      Thanks-To:  Jake Dallimore <jake@moodle.com>
      76a3cf95
  24. 29 Apr, 2019 1 commit
  25. 08 Apr, 2019 1 commit
  26. 29 Mar, 2019 1 commit
  27. 06 Mar, 2019 1 commit
  28. 18 Jan, 2019 1 commit
  29. 13 Nov, 2018 1 commit
    • Andrew Nicols's avatar
      MDL-53566 core: Add support for context locking · 0616f045
      Andrew Nicols authored
      This chagne adds support for a new feature known as Context Locking.
      This allows a context to be locked, thereby removing all write
      capabilities for all users (including admin) for that context, and all
      child contexts.
      0616f045
  30. 09 Oct, 2018 1 commit
    • Damyon Wiese's avatar
      MDL-61378 forum: Standardize HTML output for posts · 1bf3a76a
      Damyon Wiese authored
      Improve the format of the HTML representing a forum post.
      
      1. Use <article> tag to mark it correctly.
      2. Use <time> tag to include the real datetime information.
      3. Use <address> tag to specify who and when the post came from.
      4. Use heading level tags to mark the subject of each post.
      5. Properly nest reply posts within their parent <article>
      6. Use a header tab for each article to split the metadata from the content.
      7. Use CSS to separate links, not text content.
      
      Because posts are now nested properly, the heading for each one refers to it's own article
      and we don't need to generate arbitrary heading level tags depending on how deep the post
      is nested.
      1bf3a76a
  31. 05 Oct, 2018 1 commit
  32. 27 Jul, 2018 1 commit
  33. 03 May, 2018 2 commits
  34. 26 Mar, 2018 1 commit
  35. 09 Mar, 2018 1 commit