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

Migrate all "old" FakeDBUnitTestCase to UnitTestCaseUsingDatabase counterparts

    Details

    • Type: Task
    • Status: Closed
    • Priority: Critical
    • Resolution: Duplicate
    • Affects Version/s: 2.0
    • Fix Version/s: None
    • Component/s: Unit tests
    • Labels:
    • Difficulty:
      Difficult
    • Affected Branches:
      MOODLE_20_STABLE

      Description

      Some months ago FakeDBUnitTestCase were left nominally out. With that, an important number of tests have remained "hidden" (skipped) since then.

      Since yesterday (Nov 30th 2009), due to MDL-21007, they are, at least, showed as exceptions when running unit tests with message:

      "Unit test XXXX of type FakeDBUnitTestCase no longer supported. Must be migrated to UnitTestCaseUsingDatabase"

      So current tests in core using FakeDBUnitTestCase must be migrated to newer UnitTestCaseUsingDatabase alternative. That includes, at least:

      • grade tests
      • portfolio tests
      • completion and condition tests
      • simpletest tests

      So steps are:

      • Migrate all the tests
      • Document UnitTestCaseUsingDatabase
      • Drop FakeDBUnitTestCase completely from HEAD

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Votes:
                  2 Vote for this issue
                  Watchers:
                  5 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: