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

Moodle XML question import sometimes fails to import files

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.1.5, 2.2.2
    • Fix Version/s: 2.1.6, 2.2.3
    • Component/s: Questions
    • Labels:
    • Testing Instructions:
      Hide

      Ideally, we need to test a lot of different combinations here.

      1A. Create some questions in a question category belonging to a course, with images embedded in various bits of the question text.

      1B. Create some questions in a question category belonging to a quiz, with images embedded in various bits of the question text.

      2A. Export the questions selecting both "Write category to file" and "Write context to file".

      2B. Export the questions selecting Just "Write category to file".

      2C. Export the questions selecting neither "Write category to file" nor "Write context to file".

      3A. Go to the question import page, and set the Import category to a course-level category.

      3B. Go to the question import page, and set the Import category to a quiz-level category.

      4A. Turn on both "Get category from file" and "Get context from file".

      4B. Turn on just "Get category from file"

      4C. Turn on neither "Get category from file" nor "Get context from file".

      5. Import the file you you exported in 2. above. Verify that the questions are imported into a category that is added in the right place in the question bank, and that the images in the questions are still there.

      In total, this is 2x3x2x3 = 36 possible combinations. I do not seriously expect you to test them all, just test a few different combinations, that between them cover each option at least once.

      Show
      Ideally, we need to test a lot of different combinations here. 1A. Create some questions in a question category belonging to a course, with images embedded in various bits of the question text. 1B. Create some questions in a question category belonging to a quiz, with images embedded in various bits of the question text. 2A. Export the questions selecting both "Write category to file" and "Write context to file". 2B. Export the questions selecting Just "Write category to file". 2C. Export the questions selecting neither "Write category to file" nor "Write context to file". 3A. Go to the question import page, and set the Import category to a course-level category. 3B. Go to the question import page, and set the Import category to a quiz-level category. 4A. Turn on both "Get category from file" and "Get context from file". 4B. Turn on just "Get category from file" 4C. Turn on neither "Get category from file" nor "Get context from file". 5. Import the file you you exported in 2. above. Verify that the questions are imported into a category that is added in the right place in the question bank, and that the images in the questions are still there. In total, this is 2x3x2x3 = 36 possible combinations. I do not seriously expect you to test them all, just test a few different combinations, that between them cover each option at least once.
    • Affected Branches:
      MOODLE_21_STABLE, MOODLE_22_STABLE
    • Fixed Branches:
      MOODLE_21_STABLE, MOODLE_22_STABLE
    • Pull from Repository:
    • Pull Master Branch:

      Description

      This bug only happens in the following situation:

      1. The questions were exported from the MODULE-level question bank for a particular quiz.

      2. The questions are being imported into the MODULE-level of the question bank in another (or the same) quiz.

      3. In the Import from, Import category is set to one of the COURSE-level question categories.

      4. The two options "Get category from file" and "Get context from file" are both turned on.

      (Congratulations to Phil Butcher of the OU for actually finding this bug!)

        Gliffy Diagrams

          Attachments

            Activity

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  14/May/12