Skip to content

Commit

Permalink
MDL-37046 behat: Split in different classes
Browse files Browse the repository at this point in the history
  • Loading branch information
David Monllao committed Jan 29, 2013
1 parent 9516712 commit b5c1300
Show file tree
Hide file tree
Showing 8 changed files with 620 additions and 494 deletions.
4 changes: 2 additions & 2 deletions admin/tool/behat/cli/util.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

require(__DIR__ . '/../../../../config.php');
require_once($CFG->libdir . '/clilib.php');
require_once($CFG->dirroot . '/' . $CFG->admin . '/tool/behat/locallib.php');
require_once($CFG->libdir . '/behat/behat_util.php');

// CLI options.
list($options, $unrecognized) = cli_get_params(
Expand Down Expand Up @@ -75,7 +75,7 @@
exit(0);
}

tool_behat::switchenvironment($action);
behat_util::switchenvironment($action);

mtrace(get_string('testenvironment' . $action, 'tool_behat'));

3 changes: 2 additions & 1 deletion admin/tool/behat/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
require(__DIR__ . '/../../../config.php');
require_once($CFG->libdir.'/adminlib.php');
require_once($CFG->dirroot . '/' . $CFG->admin . '/tool/behat/locallib.php');
require_once($CFG->libdir . '/behat/classes/behat_config_manager.php');

$filter = optional_param('filter', '', PARAM_ALPHANUMEXT);
$type = optional_param('type', false, PARAM_ALPHAEXT);
Expand All @@ -39,7 +40,7 @@
$componentswithsteps = array('' => get_string('allavailablesteps', 'tool_behat'));

// Complete the components list with the moodle steps definitions.
$components = tool_behat::get_components_steps_definitions();
$components = behat_config_manager::get_components_steps_definitions();
if ($components) {
foreach ($components as $component => $filepath) {
// TODO Use a class static attribute instead of the class name.
Expand Down

0 comments on commit b5c1300

Please sign in to comment.