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

behat config settings and init code can be simplified

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide

      1/ set all three required $CFG->behat_xxx settings being $CFG->behat_dataroot an unexisting directory (with write permissions on the parent dir though), try init and behat run (you can terminate the run if it starts)
      2/ try breaking each of the settings in different ways - now CLI scripts should always tell you what exactly is wrong
      3/ the WWW access complaints only if the $CFG->behat_wwwroot matches, in other cases it shouldredirect to standard $CFG->wwwroot if present
      4/ try to remove $CFG->dataroot, $CFG->wwwroot and $CFG->prefix - the behat should work fine without them

      Show
      1/ set all three required $CFG->behat_xxx settings being $CFG->behat_dataroot an unexisting directory (with write permissions on the parent dir though), try init and behat run (you can terminate the run if it starts) 2/ try breaking each of the settings in different ways - now CLI scripts should always tell you what exactly is wrong 3/ the WWW access complaints only if the $CFG->behat_wwwroot matches, in other cases it shouldredirect to standard $CFG->wwwroot if present 4/ try to remove $CFG->dataroot, $CFG->wwwroot and $CFG->prefix - the behat should work fine without them
    • Affected Branches:
      MOODLE_26_STABLE
    • Fixed Branches:
      MOODLE_27_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      w51_MDL-43213_m27_simplebehat
    • Story Points:
      8
    • Sprint:
      BACKEND Sprint 8

      Description

      While testing behat settings recently I was confused by the settings and later even more when looking at the code itself. Here is my attempt to simplify all this:

      1/ always require 3 behat settings - $CFG->behat_wwwroot, $CFG->behat_dataroot and $CFG->behat_prefix
      2/ cleanup script init code
      3/ do not require $CFG->wwwroot and $CFG->dataroot on test sites
      4/ remove switch completely - the most confusing part for me
      5/ print out behat_wwwwroot in init script so that you can test the test site manually

        Attachments

          Issue Links

            Activity

              People

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

                Dates

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