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

unit tests using pattern match not correctly escaped

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.2.8
    • Fix Version/s: 2.5
    • Component/s: Questions, Quiz
    • Labels:
    • Testing Instructions:
      Hide

      1. Run all the unit tests.

      Please also do a quick test for regressions, through the Moodle UI.

      2. Create a shortanswer question that uses * wildcards to match string patterns. For example, you could ask the question "Type a string that includes |." with answer '|'.

      3. Preview that question a few times, and try a few possible responses.

      Show
      1. Run all the unit tests. Please also do a quick test for regressions, through the Moodle UI. 2. Create a shortanswer question that uses * wildcards to match string patterns. For example, you could ask the question "Type a string that includes |." with answer ' | '. 3. Preview that question a few times, and try a few possible responses.
    • Affected Branches:
      MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_25_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      We need to change all places where preg_quote has been used to include a second parameter to preg_quote, the delimiter '/'. Otherwise the delimiter is not escaped.

        Attachments

          Activity

            People

            Assignee:
            timhunt Tim Hunt
            Reporter:
            jamiesensei Jamie Pratt
            Integrator:
            Dan Poltawski
            Tester:
            Michael de Raadt
            Participants:
            Component watchers:
            Tim Hunt, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze, Tim Hunt, Andrew Nicols, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Fix Release Date:
              14/May/13