This commit is contained in:
Eloy Lafuente (stronk7) 2016-07-19 12:13:00 +02:00
commit a900c680ba

View File

@ -54,6 +54,10 @@ class behat_forms extends behat_base {
// Ensures the button is present.
$buttonnode = $this->find_button($button);
// Focus on button to ensure it is in viewport, before pressing it.
if ($this->running_javascript()) {
$buttonnode->focus();
}
$buttonnode->press();
}