MDL-56898 behat: Focus only works with JS
This commit is contained in:
@@ -65,7 +65,9 @@ class behat_enrol extends behat_base {
|
||||
$this->execute("behat_forms::i_set_the_following_fields_to_these_values", $table);
|
||||
|
||||
// Ensure we get button in focus, before pressing button.
|
||||
$this->execute("behat_general::i_take_focus_off_field", array(get_string('addinstance', 'enrol'), "button"));
|
||||
if ($this->running_javascript()) {
|
||||
$this->execute("behat_general::i_take_focus_off_field", array(get_string('addinstance', 'enrol'), "button"));
|
||||
}
|
||||
|
||||
// Save changes.
|
||||
$this->execute("behat_forms::press_button", get_string('addinstance', 'enrol'));
|
||||
|
||||
Reference in New Issue
Block a user