Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-41600

qformat_blackboard_six tests fails if ddmatch installed

    Details

    • Testing Instructions:
      Hide

      Run without ddmatch installed:
      phpunit question/format/blackboard_six/tests/blackboardformatpool_test.php
      phpunit question/format/blackboard_six/tests/blackboardsixformatqti_test.php

      Run it again after installing ddmatch.

      Verify the tests pass in both cases.

      _Plugin: https://github.com/jmvedrine/moodle-qtype_ddmatch_

      Show
      Run without ddmatch installed: phpunit question/format/blackboard_six/tests/blackboardformatpool_test.php phpunit question/format/blackboard_six/tests/blackboardsixformatqti_test.php Run it again after installing ddmatch. Verify the tests pass in both cases. _Plugin: https://github.com/jmvedrine/moodle-qtype_ddmatch_
    • Affected Branches:
      MOODLE_24_STABLE, MOODLE_25_STABLE
    • Fixed Branches:
      MOODLE_24_STABLE, MOODLE_25_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      If you have qtype_ddmatch installed, qformat_blackboard_six will generate ddmatch questions for QUESTION_MATCHING in the blackboard xml instead of qtype_match ones.

      As explained in the process_matching code of the format, this is because match actually loses data, ddmatch retains it all correctly.

      The fix is to use the same "is ddmatch installed" check in the test, and to set the expected qtype and subanswers to the relevant output.

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            fred Frédéric Massart added a comment -

            Hi Adam,

            thanks for reporting this and providing a patch. Your patch looks really good. Could you please just use the constants instead of raw values for the keys format?

            Cheers,
            Fred

            Show
            fred Frédéric Massart added a comment - Hi Adam, thanks for reporting this and providing a patch. Your patch looks really good. Could you please just use the constants instead of raw values for the keys format? Cheers, Fred
            Hide
            aolley Adam Olley added a comment -

            Hi Fred,

            You'd think I wouldn't forget that with the constants used /right above/ where I used the raw number instead.

            Fix'd on all 3 branches

            Show
            aolley Adam Olley added a comment - Hi Fred, You'd think I wouldn't forget that with the constants used /right above/ where I used the raw number instead. Fix'd on all 3 branches
            Hide
            fred Frédéric Massart added a comment -

            Awesome, thanks! Pushing for integration now.

            Show
            fred Frédéric Massart added a comment - Awesome, thanks! Pushing for integration now.
            Hide
            timhunt Tim Hunt added a comment -

            Adam, the first line of your commit comment is too long. http://docs.moodle.org/dev/Commit_cheat_sheet. Would be good if you could amend that before this is integrated.

            Otherwise, +1 from me too.

            Show
            timhunt Tim Hunt added a comment - Adam, the first line of your commit comment is too long. http://docs.moodle.org/dev/Commit_cheat_sheet . Would be good if you could amend that before this is integrated. Otherwise, +1 from me too.
            Hide
            aolley Adam Olley added a comment -

            Done, also rebased commits onto the latest state of the branches from moodle's github.

            Show
            aolley Adam Olley added a comment - Done, also rebased commits onto the latest state of the branches from moodle's github.
            Hide
            samhemelryk Sam Hemelryk added a comment -

            Thanks Adam this has been integrated now.

            Show
            samhemelryk Sam Hemelryk added a comment - Thanks Adam this has been integrated now.
            Hide
            phalacee Jason Fowler added a comment -

            All good, thanks Adam

            Show
            phalacee Jason Fowler added a comment - All good, thanks Adam
            Hide
            damyon Damyon Wiese added a comment -

            This issue along with 77 of it's friends has been sent upstream and released to the world.

            Thankyou for your contribution.

            Show
            damyon Damyon Wiese added a comment - This issue along with 77 of it's friends has been sent upstream and released to the world. Thankyou for your contribution.

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  11/Nov/13