mirror of
https://github.com/moodle/moodle.git
synced 2025-04-27 11:23:06 +02:00
MDL-46891 behat: Allow replacing string in profile for parallel run
Adding a replace with run process in profile should be allowed
This commit is contained in:
parent
0758e02e84
commit
8c66773dac
@ -120,10 +120,14 @@ $tags = '';
|
||||
|
||||
if ($options['profile']) {
|
||||
$profile = $options['profile'];
|
||||
if (!isset($CFG->behat_config[$profile]) && !isset($CFG->behat_profiles[$profile])) {
|
||||
|
||||
// If profile passed is not set, then exit.
|
||||
if (!isset($CFG->behat_config[$profile]) && !isset($CFG->behat_profiles[$profile]) &&
|
||||
!(isset($options['replace']) && (strpos($options['profile'], $options['replace']) >= 0 ))) {
|
||||
echo "Invalid profile passed: " . $profile . PHP_EOL;
|
||||
exit(1);
|
||||
}
|
||||
|
||||
$extraopts[] = '--profile="' . $profile . '"';
|
||||
// By default, profile tags will be used.
|
||||
if (!empty($CFG->behat_config[$profile]['filters']['tags'])) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user