1. 31 Mar, 2021 1 commit
  2. 11 Nov, 2020 1 commit
  3. 21 Oct, 2020 2 commits
    • Eloy Lafuente's avatar
      MDL-67673 phpunit: Remove deprecated non-public attribute assertions · a293b3ae
      Eloy Lafuente authored
      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"
      a293b3ae
    • Eloy Lafuente's avatar
      MDL-67673 phpunit: Fix the return type of template methods · f6711bb3
      Eloy Lafuente authored
      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...
      f6711bb3
  4. 14 Oct, 2019 1 commit
    • Tim Hunt's avatar
      MDL-66821 question behat: new step for acting on questions in the bank · 9c14b28d
      Tim Hunt authored
      There is a proposed change MDL-66816 which will change the question
      bank UI. This will break any Behat tests which uses low-level steps
      like
      
          When I click on "Duplicate" "link" in the "Test question" "table_row"
      
      to perform an action on a question in the question bank. This commit
      introduces a new step:
      
          When I choose "Duplicate" action for "Test question" in the question bank
      
      This commit also converts all core Behat tests to use the new step.
      9c14b28d
  5. 20 Sep, 2018 1 commit
  6. 29 Aug, 2018 1 commit
  7. 20 Aug, 2018 1 commit
  8. 03 Apr, 2017 2 commits
  9. 03 Jan, 2017 1 commit
  10. 18 Feb, 2016 1 commit
    • Eloy Lafuente's avatar
      MDL-52964 Qtype: Small fixes to behat tests · 12d5994f
      Eloy Lafuente authored
      This applies some small changes to proposed behat tests:
      
      - Geting rid of the @javascript tag when it's not needed.
      - Adding some missing @_switch_window tags.
      - Fixing some scenario names, previously duplicated.
      - Fixing some typos and whitespace.
      12d5994f
  11. 11 Feb, 2016 1 commit
  12. 09 Jan, 2015 1 commit
  13. 02 Mar, 2014 1 commit
    • Tim Hunt's avatar
      MDL-43749 normalise quiz database structure. · ccba5b88
      Tim Hunt authored
      The sequence of questions that made up a quiz used to be stored as a
      comma-separated list in quiz.questions. Now the same information is
      stored in the rows in the quiz_slots table. This is not just 'better' in
      a database design sense, but it allows for the future changes we will
      need as we enhance the quiz in the MDL-40987 epic.
      
      Having changed the database structure, all the rest of the code needs to
      be changed to account for it, and that is done here.
      
      Note that there are not many unit tests for the changed bit. That is
      because as part of MDL-40987 we will be changing the code further, and
      we will add unit tests then.
      ccba5b88
  14. 18 Feb, 2014 1 commit
  15. 22 Nov, 2013 1 commit
    • Tim Hunt's avatar
      MDL-43000 shortanswer qtype: handle patterns with many *s · 5dbfbc82
      Tim Hunt authored
      Teachers were typing patterns like
      ********************************<em>****************************</em>
      which translates into a pattern like .*.*.*.*, which is very inefficient
      to try to match, althought it is equivalent ot a single .*. At a certain
      point preg was just giving up.
      
      Since people actually do this, we should simplify the regex by treating
      runs of * like a single *.
      5dbfbc82
  16. 05 Oct, 2013 1 commit
  17. 09 Jul, 2013 1 commit
  18. 09 Apr, 2013 1 commit
  19. 29 Mar, 2013 1 commit
    • Tim Hunt's avatar
      MDL-38538 question unit tests: improve things a bit. · eca230b5
      Tim Hunt authored
      1. Split the question_attempt tests into one class per file.
      2. Imporve the API to give tests more control, and to test more of the
         important code. Some of this is not used here, but it is about to be.
      eca230b5
  20. 19 Mar, 2013 1 commit
  21. 18 Jan, 2013 1 commit
  22. 19 Dec, 2012 1 commit
  23. 10 Apr, 2012 1 commit
    • Petr Skoda's avatar
      MDL-32323 convert question tests · 603bd001
      Petr Skoda authored
      1/ type/match/tests/walkthrough_test.php - tests are failing randomly, looks like some weird randomisation is going on there - see TODOs
      
      2/ type/multianswer/tests/upgradelibnewqe_test.php contains invalid expected value - see TODO
      603bd001