Merge branch 'MDL-43235_26' of git://github.com/dmonllao/moodle into MOODLE_26_STABLE
This commit is contained in:
@@ -150,11 +150,6 @@ class tool_behat_testcase extends advanced_testcase {
|
||||
$this->markTestSkipped('Behat not installed.');
|
||||
}
|
||||
|
||||
// It is possible that it has no value.
|
||||
if (empty($CFG->behat_wwwroot)) {
|
||||
$CFG->behat_wwwroot = behat_get_wwwroot();
|
||||
}
|
||||
|
||||
// To avoid user value at config.php level.
|
||||
unset($CFG->behat_config);
|
||||
|
||||
@@ -178,6 +173,9 @@ class tool_behat_testcase extends advanced_testcase {
|
||||
// directories values.
|
||||
$this->assertContains($CFG->dirroot . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'behat' . DIRECTORY_SEPARATOR . 'features', $contents);
|
||||
|
||||
// If it was empty should be filled by behat_config_manager::get_config_file_contents().
|
||||
$this->assertNotNull($CFG->behat_wwwroot);
|
||||
|
||||
// Not quoted strings.
|
||||
$this->assertContains('micarro: /me/lo/robaron', $contents);
|
||||
$this->assertContains('class: behat_init_context', $contents);
|
||||
|
||||
@@ -173,6 +173,11 @@ class behat_config_manager {
|
||||
// We require here when we are sure behat dependencies are available.
|
||||
require_once($CFG->dirroot . '/vendor/autoload.php');
|
||||
|
||||
// It is possible that it has no value.
|
||||
if (empty($CFG->behat_wwwroot)) {
|
||||
$CFG->behat_wwwroot = behat_get_wwwroot();
|
||||
}
|
||||
|
||||
$basedir = $CFG->dirroot . DIRECTORY_SEPARATOR . 'lib' . DIRECTORY_SEPARATOR . 'behat';
|
||||
$config = array(
|
||||
'default' => array(
|
||||
|
||||
Reference in New Issue
Block a user