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

Behat switches completely to test mode if $CFG->behat_switchcompletely is set to false

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide
      1. Edit your config.php file and add $CFG->behat_switchcompletely = false;
      2. Update your testing environment and --enable it again to refresh the config file
      3. Run the tests (don't start the built-in server)
      4. You SHOULD see an exception stating that localhost:8000 (or $CFG->behat_wwwroot if you overwrote this setting) is not available
      Show
      Edit your config.php file and add $CFG->behat_switchcompletely = false; Update your testing environment and --enable it again to refresh the config file Run the tests (don't start the built-in server) You SHOULD see an exception stating that localhost:8000 (or $CFG->behat_wwwroot if you overwrote this setting) is not available
    • Affected Branches:
      MOODLE_25_STABLE
    • Fixed Branches:
      MOODLE_25_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-38164_master

      Description

      Discovered by Fred while working on the MDK behat script. A wrong use of isset() rather than !empty() makes the site switch to test mode (only if test mode has been -enable) if $CFG>behat_switchcompletely = false, the condition should require (!empty($1) && $1 === true)

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              dmonllao David Monllaó
              Reporter:
              dmonllao David Monllaó
              Integrator:
              Dan Poltawski Dan Poltawski
              Tester:
              Andrew Davis Andrew Davis
              Participants:
              Component watchers:
              Andrew Lyons, Dongsheng Cai, Huong Nguyen, Jun Pataleta, Michael Hawkins, Shamim Rezaie, Simey Lameze
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

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