This commit is contained in:
Eloy Lafuente (stronk7) 2017-01-03 02:34:58 +01:00
commit 0e5205d36c
4 changed files with 4 additions and 26 deletions

View File

@ -386,28 +386,6 @@ class behat_hooks extends behat_base {
$this->resize_window('medium');
}
/**
* Executed after scenario to go to a page where no JS is executed.
* This will ensure there are no unwanted ajax calls from browser and
* site can be reset safely.
*
* @param AfterScenarioScope $scope scope passed by event fired after scenario.
* @AfterScenario
*/
public function after_scenario(AfterScenarioScope $scope) {
try {
$this->wait_for_pending_js();
$this->getSession()->reset();
} catch (DriverException $e) {
// Try restart session, if DriverException caught.
try {
$this->getSession()->restart();
} catch (DriverException $e) {
// Do nothing, as this will be caught while starting session in before_scenario.
}
}
}
/**
* Wait for JS to complete before beginning interacting with the DOM.
*

View File

@ -34,7 +34,7 @@ Feature: Add preconfigured tools via teacher interface
And the field "Icon URL" matches value "http://download.moodle.org/unittest/test.jpg"
And the field "Secure icon URL" matches value "https://download.moodle.org/unittest/test.jpg"
@javascript
@javascript @_switch_window
Scenario: Add a preconfigured tool from a cartridge
When I log in as "teacher1"
And I follow "Course 1"
@ -58,7 +58,7 @@ Feature: Add preconfigured tools via teacher interface
And I press "Cancel"
And I switch to the main window
@javascript
@javascript @_switch_window
Scenario: Add and use a preconfigured tool
When I log in as "teacher1"
And I follow "Course 1"

View File

@ -1,4 +1,4 @@
@mod @mod_scorm @_file_upload @_switch_frame
@mod @mod_scorm @_file_upload @_switch_iframe
Feature: Add scorm activity
In order to let students access a scorm package
As a teacher

View File

@ -1,4 +1,4 @@
@mod @mod_scorm @_file_upload @_switch_frame
@mod @mod_scorm @_file_upload @_switch_iframe
Feature: Scorm multi-sco completion
In order to let students access a scorm package
As a teacher