Browse files

Merge branch 'MDL-39717_25' of git://github.com/dmonllao/moodle into …

…MOODLE_25_STABLE
  • Loading branch information...
2 parents 99f5bad + c340dca commit e3c1bd25935c5e748a5a29a9c6c3895e2bee4734 @stronk7 stronk7 committed May 20, 2013
View
4 course/tests/behat/behat_course.php
@@ -433,7 +433,7 @@ public function activity_should_be_hidden($activityname) {
}
/**
- * Moves the specified activity to the first slot of a section. Editing mode should be on.
+ * Moves the specified activity to the first slot of a section. This step is experimental when using it in Javascript tests. Editing mode should be on.
*
* @Given /^I move "(?P<activity_name_string>(?:[^"]|\\")*)" activity to section "(?P<section_number>\d+)"$/
* @param string $activityname The activity name
@@ -528,7 +528,7 @@ public function i_indent_left_activity($activityname) {
}
/**
- * Deletes the activity or resource specified by it's name. You should be in the course page with editing mode on.
+ * Deletes the activity or resource specified by it's name. This step is experimental when using it in Javascript tests. You should be in the course page with editing mode on.
*
* @Given /^I delete "(?P<activity_name_string>(?:[^"]|\\")*)" activity$/
* @param string $activityname
View
11 course/tests/behat/course_controls.feature
@@ -4,10 +4,10 @@ Feature: Course activity controls works as expected
As a teacher
I need to edit, hide, show and indent activities inside course sections
- # This two scenario outlines contains exactly the same steps, the
- # only difference is whether JS is enabled or not; we can not use
- # Background sections when using Scenario Outlines because of Behat
- # framework restrictions.
+ # The difference between these two scenario outlines is that one is with
+ # JS enabled and the other one with JS disabled, also with JS disabled we
+ # add the delete activity checking; we can not use Background sections
+ # when using Scenario Outlines because of Behat framework restrictions.
# We are testing:
# * Javascript on and off
@@ -61,9 +61,6 @@ Feature: Course activity controls works as expected
And "#section-2" "css_element" <should_see_other_sections> exists
And I click on "Hide" "link" in the "Test forum name 1" activity
And "#section-2" "css_element" <should_see_other_sections> exists
- And I delete "Test forum name 1" activity
- And "#section-2" "css_element" <should_see_other_sections> exists
- And I should not see "Test forum name 1" in the ".region-content" "css_element"
And I duplicate "Test forum name 2" activity editing the new copy with:
| Forum name | Edited test forum name 2 |
And "#section-2" "css_element" <should_see_other_sections> exists
View
19 course/tests/behat/move_activities.feature
@@ -27,25 +27,6 @@ Feature: Activities can be moved between sections
| Forum name | Test forum name |
| Description | Test forum description |
- @javascript @_cross_browser
- Scenario: Move activities in a single page course with Javascript enabled
- When I move "Test forum name" activity to section "2"
- And I reload the page
- Then I should see "Test forum name" in the "#section-2" "css_element"
- And I should not see "Test forum name" in the "#section-1" "css_element"
-
- @javascript @_cross_browser
- Scenario: Move activities in the course home with Javascript enabled using paged mode
- Given I follow "Edit settings"
- And I fill the moodle form with:
- | Course layout | Show one section per page |
- And I press "Save changes"
- When I move "Test forum name" activity to section "2"
- # This reload step is added because of drap&drop & yui dd problem
- And I reload the page
- Then I should see "Test forum name" in the "#section-2" "css_element"
- And I should not see "Test forum name" in the "#section-1" "css_element"
-
Scenario: Move activities in a single page course with Javascript disabled
When I move "Test forum name" activity to section "2"
Then I should see "Test forum name" in the "#section-2" "css_element"
View
4 lib/tests/behat/behat_general.php
@@ -83,7 +83,7 @@ public function switch_to_the_main_window() {
}
/**
- * Accepts the currently displayed alert dialog.
+ * Accepts the currently displayed alert dialog. This step does not work in all the browsers, consider it experimental.
* @Given /^I accept the currently displayed dialog$/
*/
public function accept_currently_displayed_alert_dialog() {
@@ -188,7 +188,7 @@ public function i_click_on_in_the_table_row($element, $selectortype, $tablerowte
}
/**
- * Drags and drops the specified element to the specified container. This step is experimental.
+ * Drags and drops the specified element to the specified container. This step does not work in all the browsers, consider it experimental.
*
* The steps definitions calling this step as part of them should
* manage the wait times by themselves as the times and when the

0 comments on commit e3c1bd2

Please sign in to comment.